https://bugzilla.wikimedia.org/show_bug.cgi?id=24662

           Summary: escaping whitespaces in style-attributes
           Product: MediaWiki
           Version: unspecified
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: Normal
         Component: Page rendering
        AssignedTo: wikibugs-l@lists.wikimedia.org
        ReportedBy: andbe...@web.de


Some browsers dont like it when there are unusual whitespaces in the
style-attribute of an HTML-tag (means: they cant display the CSS in the correct
way). This causes some template errors like
[http://de.wikipedia.org/wiki/Wikipedia:WikiProjekt_Vorlagen/Werkstatt#commons:Template:Bar_box_und_commons:Template:Bar_pixel
here]. The template uses unnamed parameters in its style-attributes, and an
include whith one line per parameter causes that the line break can still be
found in the HTML source code.
You can solve the Problem by using ParserFunctions in the template like 
 style="background:{{#if:TRUE|{{{1|none}}}}};"
but that is not as good as doing this by the parser also. This could be done by
an regularExpression like that:
 replace(/[\s\n\r\t]+, " "); //I'm not an expert
Also   and Co are not likely seen by some browsers.

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
You are on the CC list for the bug.

_______________________________________________
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to