Last modified: 2014-06-25 20:41:10 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T69092, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 67092 - Parser inserts invalid   in the middle of style attribute
Parser inserts invalid   in the middle of style attribute
Status: RESOLVED DUPLICATE of bug 3158
Product: MediaWiki
Classification: Unclassified
Parser (Other open bugs)
unspecified
All All
: Unprioritized major (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-06-25 19:12 UTC by Krinkle
Modified: 2014-06-25 20:41 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Krinkle 2014-06-25 19:12:57 UTC
When the parser strips a /* comment */ from a style attribute it inserts a   in its place. This causes the stylesheet to be invalidated by the browser and the relevant styles are not applied when the page is renders.


Wikitext input:

<blockquote style="border: 1px solid #aaa /* foo */;"></blockquote>

Expected output:

<blockquote style="border: 1px solid #aaa ;"></blockquote>
or
<blockquote style="border: 1px solid #aaa;"></blockquote>

Actual output:

<blockquote style="border: 1px solid #aaa &#160;;"></blockquote>

A nbsp; is illegal in css in that position and results in a parse error by the browser, causing the 'border' rule in this case to not be applied.
Comment 1 Gerrit Notification Bot 2014-06-25 19:14:06 UTC
Change 142042 had a related patch set uploaded by Krinkle:
[WIP] Parser: Don't insert &nbsp; inside style attributes

https://gerrit.wikimedia.org/r/142042
Comment 2 Bartosz Dziewoński 2014-06-25 20:41:10 UTC

*** This bug has been marked as a duplicate of bug 3158 ***

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links