[TxMt] Weird HTML Comment Issue?
Eric Coleman
eric at aplosmedia.com
Sat May 6 03:48:15 UTC 2006
Thanks Allan,
It's not my source code, or i'd have fixed them all by now... guy I
work with, but thanks for the information.
Eric Coleman
On May 5, 2006, at 11:16 PM, Allan Odgaard wrote:
> On 6/5/2006, at 4:55, Eric Coleman wrote:
>
>> I've noticed that the HTML comments are slightly restrictive.
>
> Indeed they are :)
>
>> If I have the following code: [...] <!--- order now ---> [...] it
>> will highlight everything from the start of the comment, to the
>> end of the page. How do I fix that without going through all the
>> flies to fix the comments?
>
> From the HTML standard chapter 3.2.4:
>
> [...] A common error is to include a string of
> hyphens ("---") within a comment. Authors should
> avoid putting two or more adjacent hyphens inside
> comments.
>
> So I would suggest fixing your comments (search’n’replace). While
> the HTML standard doesn’t explicitly say it (anymore, I think it
> did in the past), HTML comments come from SGML, and here ‘--’
> changes state in the parser. So your last ‘--->’ is (if this was a
> strict parser) seen as ‘--’, which goes into a mode where it
> expects whitespace or a ‘>’ (to terminate the comment), but instead
> it finds another dash (‘-’).
>
>
>
> ______________________________________________________________________
> For new threads USE THIS: textmate at lists.macromates.com
> (threading gets destroyed and the universe will collapse if you don't)
> http://lists.macromates.com/mailman/listinfo/textmate
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3696 bytes
Desc: not available
URL: <http://lists.macromates.com/textmate/attachments/20060505/d3baa52e/attachment.p7s>
More information about the textmate
mailing list