Opt-out/in iframe code is not following HTML standard #4022

Closed
anonymous-piwik-user opened this Issue Jun 25, 2013 · 7 comments

4 participants

@anonymous-piwik-user

It looks like this:

<iframe frameborder="no" width="600px" height="200px" src="http://foo.bar/index.php?module=CoreAdminHome&action=optOut&language=en"></iframe>

But should looks like this:

<iframe frameborder="no" width="600" height="200" src="http://foo.bar/index.php?module=CoreAdminHome&action=optOut&language=en"></iframe>

Because there are "pixels by default", values of those attributes should be just numbers. See http://www.w3.org/TR/html4/present/frames.html#h-16.5 or try to validate this code in validator.nu, you will get info that "p" after 200 and 600 is not a number.

That code could even look like:

<iframe style="border: 0; height: 200x; width: 600px" src="http://foo.bar/index.php?module=CoreAdminHome&action=optOut&language=en"></iframe>

Because it's good to use CSS for presentation, even in-line, and frameborder attribute is obsolete in HTML5.
Keywords: html, css, opt-out

@anonymous-piwik-user

Of course last code should be:

<iframe style="border: 0; height: 200px; width: 600px" src="http://foo.bar/index.php?module=CoreAdminHome&action=optOut&language=en"></iframe>

Sorry, I was fighting with time to not be logged out again before clicking "Create ticket"

@mattab
Piwik Open Source Analytics member

Please can you propose pull request? http://piwik.org/participate/contributing-with-git/

@anonymous-piwik-user

In 1828305: Fix iframe width/height

fixes #4022
skip

@sgiehl
Piwik Open Source Analytics member

In e7108e6: refs #4022 fixed typo

@anonymous-piwik-user

In 770fd36: refs #4022 Fix iframe attributes in privacy settings

Original fix was only applied to plugins/CoreAdminHome/templates/generalSettings.twig.

@mattab
Piwik Open Source Analytics member

In 013f3a2: Merge pull request #253 from fhemberger/fix-optout-iframe

refs #4022 Fix iframe attributes in privacy settings

@sabl0r sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
@halfdan halfdan Fix iframe width/height
fixes #4022
[ci skip]
1828305
@sabl0r sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
@halfdan halfdan refs #4022 1404802
@sabl0r sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
@sgiehl sgiehl refs #4022 fixed typo e7108e6
@sabl0r sabl0r pushed a commit to sabl0r/piwik that referenced this issue Sep 23, 2014
@fhemberger fhemberger refs #4022 Fix iframe attributes in privacy settings
Original fix was only applied to `plugins/CoreAdminHome/templates/generalSettings.twig`.
770fd36
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment