Closed Bug 279583 Opened 20 years ago Closed 20 years ago

wrong display with html entity

Categories

(Core :: DOM: HTML Parser, defect)

x86
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 107320

People

(Reporter: intendentedelleacque, Unassigned)

References

()

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; it-IT; rv:1.7.5) Gecko/20041110 Firefox/1.0
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; it-IT; rv:1.7.5) Gecko/20041110 Firefox/1.0

According to w3c, http://www.w3.org/TR/REC-html40/charset.html#h-5.3 , it is
possible to eliminate the final ";" after a character reference in some cases
(e.g., at a line break or immediately before a tag), but in other circumstances
it may not be eliminated (e.g., in the middle of a word). 
Firefox in some combinations (in particular. entities followed by an accented
character), parses the entity even if ";" misses and the entity is in the middle
of the word, as you can see in my test page,
http://deepwave.altervista.org/test.html


Reproducible: Always

Steps to Reproduce:
1. write the html code abcde&Più in a web page
2. see the page with Firefox
3.

Actual Results:  
You see abcde + a greek Pi + an accented u

Expected Results:  
You should see abcde + &Pi + an accented u
moving to core...
Assignee: firefox → nobody
Component: General → Layout: Fonts and Text
Product: Firefox → Core
QA Contact: general → layout.fonts-and-text
Version: unspecified → Trunk
Assignee: nobody → parser
Component: Layout: Fonts and Text → HTML: Parser
QA Contact: layout.fonts-and-text → mrbkap
Among the things that marks the end of an SGML character entity reference is a
character which is not among the name characters according to the relevant SGML
declaration. HTML's SGML declaration says name characters are A-Z, a-z, 0-9 and
.-_: so when the parser hits any character not among those, that's the end and
either it's a declared character entity reference that's replaced, like &Più is,
or an invalid one, like &Pieù which would be displayed as-is.

*** This bug has been marked as a duplicate of 107320 ***
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.