Last modified: 2014-01-16 02:45:00 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 T54330, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 52330 - in tables an empty bgcolor attribute is parsed suboptimally
in tables an empty bgcolor attribute is parsed suboptimally
Status: NEW
Product: MediaWiki
Classification: Unclassified
Parser (Other open bugs)
unspecified
All All
: Normal normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-07-31 18:02 UTC by Chris McKenna
Modified: 2014-01-16 02:45 UTC (History)
4 users (show)

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


Attachments

Description Chris McKenna 2013-07-31 18:02:00 UTC
Compare the first two cells in row 1 of the table at https://en.wikipedia.org/w/index.php?title=User:Thryduulf/sandbox&oldid=566470353#Table where the Wikicode

|-
|bgcolor=""| row 1, cell 1
|bgcolor| row 1, cell 2

produces:

<tr>
<td bgcolor="">row 1, cell 1</td>
<td bgcolor="bgcolor">row 1, cell 2</td>

Row 1 cell 1 is rendered with the light grey background colour defined in the wikitable class. Row 1 cell 2 is rendered with a dark red background colour (#b00000)

The desired behaviour is that both should produce the html <td bgcolor="">
Comment 1 db [inactive,noenotif] 2013-08-03 15:48:51 UTC
From Sanitizer::getTagAttributeCallback:

# In XHTML, attributes must have a value.
# For 'reduced' form, return explicitly the attribute name here.

Works as aspected, but it the aspected right?
Comment 2 Chris McKenna 2013-08-14 07:54:55 UTC
That behaviour might be what is expected from the code specification, but the output it isn't what the end user expects.
Comment 3 Gabriel Wicke 2014-01-16 02:45:00 UTC
This is causing a difference vs. Parsoid, so it would be good to fix this in PHP. See also bug 51954.

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


Navigation
Links