Page MenuHomePhabricator

Incorrect handling of nested <em>, <strong>, <q>, <ruby>, and <bdo>
Closed, ResolvedPublic

Description

This is related to bug 41545. See also gerrit change I194167f3c0621394ab4fb40e242711ccb86615ae

The parser, when given "<em>X<em>Y</em>Z</em>" emits "<p><em>X&lt;em&gt;Y</em>Z&lt;/em&gt;</p>". The same bogus escaping also occurs for <b>.


Version: 1.22.0
Severity: normal

Details

Reference
bz51081

Event Timeline

bzimport raised the priority of this task from to Low.
bzimport set Reference to bz51081.
cscott created this task.Jul 10 2013, 12:39 AM

Note that the HTML spec (http://www.w3.org/TR/html5/text-level-semantics.html) gives an explicit meaning for nested <em>, <strong>, <q>, <ruby>, and <bdo>.

There are other nestable tags (<b>, <i>, <s>, <u>, <cite>, <dfn>, <abbr>, <time>, <code>, <mark>, <rt>, <rp>, <bdi>) which I've chosen not to fix since the spec allows but does not give semantics for them.

Change 72981 had a related patch set uploaded by Cscott:
Fix incorrect escaping of nested <em>, <strong>, <q>, <ruby>, and <bdo>

https://gerrit.wikimedia.org/r/72981

Change 72981 merged by jenkins-bot:
Fix incorrect escaping of nested <em>, <strong>, <q>, <ruby>, and <bdo>

https://gerrit.wikimedia.org/r/72981