cross browser - Is it safe to comment out large chunks of HTML code? -


is safe enclose large chunks of html (containing form elements, script tags, etc) <!-- , -->, or cause problems in browsers?

i know not ideal source control, i'm interested whether cause issues in browsers or not.

thanks.

normally it's safe... except sometimes. guess it's not safe, :-)

there might problems, specially if there scripts enclosed: 1 thing, comment should not include -- (ref). people advise against having > inside comment (ref), i'd that's extreme.

above all: cannot nest comments. so, if html code has "real" comments, in trouble.

in general, i'd using html comments "comment out" fragments of code not practice.


Comments