G
Griff
Hi there
About this business of embedding HTML comments in Javascript.
Everyone tells me that JavaScript parsing ignores any line starting
with <!--
but that I need to protect any occurrence of --> with a Javascript
comment //.
My browser (IE 6) seems to handle <!-- as described, but also seems
to ignore occurrences of -->, with or without a leading //.
I was trying to look up the official ruling on this in the
JavaScript 1.5 Guide and Reference on Netscape, but I can't seem to
find any mention of it in the various Netscape documents. So is this
an undocumented convention which JavaScript compliant browsers can
choose to handle just as they like ?
thanks
- griff
About this business of embedding HTML comments in Javascript.
Everyone tells me that JavaScript parsing ignores any line starting
with <!--
but that I need to protect any occurrence of --> with a Javascript
comment //.
My browser (IE 6) seems to handle <!-- as described, but also seems
to ignore occurrences of -->, with or without a leading //.
I was trying to look up the official ruling on this in the
JavaScript 1.5 Guide and Reference on Netscape, but I can't seem to
find any mention of it in the various Netscape documents. So is this
an undocumented convention which JavaScript compliant browsers can
choose to handle just as they like ?
thanks
- griff