This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 206 - Trailing slash on <meta/> tag (for XHTML compatability) generates error when validating as HTML 4.01 Strict
Summary: Trailing slash on <meta/> tag (for XHTML compatability) generates error when ...
Status: VERIFIED INVALID
Alias: None
Product: Validator
Classification: Unclassified
Component: Parser (show other bugs)
Version: 0.7.0
Hardware: Other other
: P2 normal
Target Milestone: ---
Assignee: Terje Bless
QA Contact:
URL: http://validator.w3.org/check?uri=htt...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-04-27 21:46 UTC by Jacob Steenhagen
Modified: 2003-04-28 04:49 UTC (History)
0 users

See Also:


Attachments

Description Jacob Steenhagen 2003-04-27 21:46:11 UTC
Because the server I'm using for school doesn't send the charset as part of the
http header I have it included as a <meta/> tag. However, when placing the
trailing slash in the tag for XHTML compatability the validator gives the
following error:

   1.  Line 15, column 75:  character data is not allowed here
       ... content="text/html; charset=ISO-8859-1" />
                                                    ^

It was discovered in our HTML class that this error also occured with <area/> tags.
Comment 1 Terje Bless 2003-04-27 23:32:37 UTC
Please see the thread starting at
<http://lists.w3.org/Archives/Public/www-validator/2003Apr/0154.html> -- and in
particular Bjoern Hoehrmann's reply at
<http://lists.w3.org/Archives/Public/www-validator/2003Apr/0155.html> -- which
deals with this.

You cannot use XHTML syntax (e.g. <meta />) in HTML 4; either change the DOCTYPE
to XHTML 1.0 or switch back to HTML 4 syntax.
Comment 2 Jacob Steenhagen 2003-04-28 00:49:24 UTC
Guess I just leanred something about how those tags are parsed.

Thanks,
Jake