Closed
Bug 268598
Opened 20 years ago
Closed 20 years ago
Short-form empty element not considered closed
Categories
(Firefox :: General, defect)
Tracking
()
VERIFIED
INVALID
People
(Reporter: md2perpe, Assigned: bugzilla)
Details
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; sv-SE; rv:1.7.5) Gecko/20041108 Firefox/1.0 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; sv-SE; rv:1.7.5) Gecko/20041108 Firefox/1.0 In the page below, the text "This shouldn't be either." shouldn't be underlined, since it isn't inside an A element. The A-tag *should* be treated as ended, especially when there is an XML declaration and the document satisfies XHTML. <?xml version="1.0" ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html> <head> <title>Underline</title> <style type="text/css"> A { text-decoration: underline; color: #3333cc; } </style> </head> <body> <p>Line 1: This text isn't underlined. <a name="anchor"></a> Neither is this.</p> <p>Line 2: This text isn't underlined. <a name="anchor" /> This shouldn't be either.</p> </body> </html> Reproducible: Always Steps to Reproduce:
Comment 1•20 years ago
|
||
You can't use short form XML closing syntax unless you serve the page as application/xhtml+xml, which I'm willing to bet you're not doing. Otherwise, the page is sent as text/html, parsed as HTML, so the Appendix C compatibility rules of XHTML 1.0 apply.
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → INVALID
| Reporter | ||
Comment 2•20 years ago
|
||
If I send the page as application/xhtml+xml, the page is shown as an XML tree. That's not what I want either; is that bug? That makes true XHTML as useless in Firefox as it is in Internet Explorer (which wants to save it as a file). Using <meta http-equiv="Content-Type" content="application/xhtml+xml" /> doesn't help either. The HTML Compatibility Guidelines are guidelines for the web designer, not rules that the user agent should demand be fulfilled. The XHTML Media Types document says, however, that XHTML "should" be served as application/xhtml+xml. But "should" doesn't mean "must". It's merely a strong recommendation. * HTML Compatibility Guidelines: http://www.w3.org/TR/xhtml1/#guidelines * XHTML Media Types: http://www.w3.org/TR/xhtml-media-types/
Status: RESOLVED → UNCONFIRMED
Resolution: INVALID → ---
Comment 3•20 years ago
|
||
(In reply to comment #2) > If I send the page as application/xhtml+xml, the page is shown as an XML tree. > That's not what I want either; is that bug? That makes true XHTML as useless > in Firefox as it is in Internet Explorer (which wants to save it as a file). I have no idea, but that's not this bug. > Using <meta http-equiv="Content-Type" content="application/xhtml+xml" /> > doesn't help either. The server's MIME type always takes precedence. > The HTML Compatibility Guidelines are guidelines for the web designer, not > rules that the user agent should demand be fulfilled. > > The XHTML Media Types document says, however, that XHTML "should" be served as > application/xhtml+xml. But "should" doesn't mean "must". It's merely a strong > recommendation. If you don't sent the file as XML, it will not be parsed as XML, so you can't use that XML syntax, period. This bug, as written for the originally stated problem, is not valid. Please do not reopen it.
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago → 20 years ago
Resolution: --- → INVALID
You need to log in
before you can comment on or make changes to this bug.
Description
•