Closed Bug 315121 Opened 19 years ago Closed 19 years ago

HTML Comment made visible if it includes -- within the message other than -->

Categories

(Firefox :: General, defect)

x86
Windows XP
defect
Not set
trivial

Tracking

()

RESOLVED DUPLICATE of bug 120385

People

(Reporter: codermsu, Unassigned)

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.12) Gecko/20050915 Firefox/1.0.7
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.12) Gecko/20050915 Firefox/1.0.7

<!-- Title -- Subtitle -->

I don't know if this is valid HTML comment or not, but in IE, the comment is not displayed.  In Firefox, all text after <!-- shows up in the browser.  



Reproducible: Always

Steps to Reproduce:
1. I created an html page with <!-- text -- text --> and checked it in the browser.
2.
3.

Actual Results:  
text -- text --> evaluates as text in the browser window. 

Expected Results:  
Not displayed the HTML comment.

<!-- <!-- text -- text --> resolves the issue.  I assume the literal string '-->' should be looked for or --[^\w+]> or something.

*** This bug has been marked as a duplicate of 120385 ***
Status: UNCONFIRMED → RESOLVED
Closed: 19 years ago
Resolution: --- → DUPLICATE
The problem with checking specifically for -- as the end delimiter for a comment is in situations where commenting out a section of a page is helpful to the developer for whatever reason.  
You need to log in before you can comment on or make changes to this bug.