Page MenuHomePhabricator

& should be escaped to & in pages' category titles
Closed, ResolvedPublic

Description

Author: zigger

Description:
& is not being escaped to & within the category titles for a normal page or
a category page.

If a page contains "[[Category:A & B]]", the category list entry text is
rendered in (X)HTML as "A & B" instead of "A & B". v1.4.5 renders this
correctly.

XML 1.0 reference: http://www.w3.org/TR/REC-xml/#syntax


Version: 1.5.x
Severity: normal
URL: http://en.wikipedia.org/wiki/Mary_II_of_England

Details

Reference
bz2567

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 8:35 PM
bzimport added a project: MediaWiki-Parser.
bzimport set Reference to bz2567.
bzimport added a subscriber: Unknown Object (MLST).
bzimport created this task.Jun 28 2005, 1:25 PM

jeluf wrote:

Has this been fixed in the meantime?

  • HTML source shows & to me -

http://validator.w3.org/check?verbose=1&uri=http%3A//en.wikipedia.org/wiki/Mary_II_of_England

says it's valid XHTML.

> Closing, please reopen if not fixed.

zigger wrote:

(In reply to comment #1)

Has this been fixed in the meantime?

No

  • HTML source shows & to me

Look for "English & British", it's one of the category titles.

http://validator.w3.org/check?verbose=1&uri=http%3A//en.wikipedia.org/wiki/Mary_II_of_England

says it's valid XHTML.

True. But it's parse tree shows the unescaped &. So I should try looking-up /
reporting a bug there sometime. Tidy finds the error.

> Closing, please reopen if not fixed.

Reopened.

brion added a comment.Jun 28 2005, 7:40 PM

Specifically:

<a href="/wiki/Category:Heirs_to_the_English_%26_British_thrones"
title="Category:Heirs to the English &amp; British thrones">Heirs to the English &
British thrones</a>

brion added a comment.Jun 28 2005, 8:00 PM

Ok, fixed now in CVS HEAD and live:
<a href="/wiki/Category:Heirs_to_the_English_%26_British_thrones"
title="Category:Heirs to the English &amp; British thrones">Heirs to the English
&amp; British thrones</a>

Removed parsertext keywords; the parser test framework cannot cover this as it's
outside of the main text output.