Hello, I'm having problems with understanding errors given by W3C's validation tool.
Could someone check out the link and help me understand the problem and solutions for these errors please?
Here's the link:
Thanks
These are comment delimiters:
These are comment delimiters: <!--
-->
These are not: <!---
--->
what happens if...
I use those correct comment delimeters and but add a space for the rest of the hyphens?
For example
Would that work?
What happened when you tried
What happened when you tried it?
What happened...
<!-- --this comment-- -->
showed the errors:
Validation Output: 2 Errors
1. Error Line 1, Column 8: invalid comment declaration: found name start character outside comment but inside comment declaration
<!-- --this comment-- -->
✉
2. Info Line 1, Column 1: comment declaration started here
<!-- --this comment-- -->
3. Error Line 1, Column 26: end of document in prolog
<!-- --this comment-- -->
✉
Yes, you are ending the
Yes, you are ending the comment early.
I don't get it.. How can I
I don't get it..
How can I make comments stand out, have you any suggestions using different characters which validate?
<!-- ########################
<!--
###################################
THESE COMMENTS WILL STAND OUT!
###################################
-->
But have a play around, test things out, see what works. There is no standard set for how comments are presented.
Thanks guys
Thanks guys
anevins wrote:I don't get
I don't get it.. ...
I'll try to clear it up. <!
is a markup declaration open delimiter, for example a doctype declarations and comment declarations. Whatever follows <!
tells you what sort of declaration it is, for example doctype
in the case of a doctype declaration.
The issue occurs because the comment open delimiter is the same as the comment close delimiter. --
both opens and closes the comment so <!-- --this comment was just closed before the word this and not after the rest of this text -->
.
Does that help?