Categories:
.NET (357)
C (330)
C++ (183)
CSS (84)
DBA (2)
General (7)
HTML (4)
Java (574)
JavaScript (106)
JSP (66)
Oracle (114)
Perl (46)
Perl (1)
PHP (1)
PL/SQL (1)
RSS (51)
Software QA (13)
SQL Server (1)
Windows (1)
XHTML (173)
Other Resources:
What Happens If a META Element Is Not Closed
What Happens If a META Element Is Not Closed? - XHTML 1.0 Tutorials - Document Structure and Head Level Tags
✍: FYIcenter.com
Meta tags, link tags and base tags must be closed in XHTML documents. If you forget to close them like the HTML format, you will get validation errors. Try the following tutorial sample XHTML document on http://validator.w3.org/ to see what types of errors you will get:
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html> <head> <title>My First XHTML Document</title> <base href="http://dev.fyicenter.com/" /> <meta name="Author" content="FYIcenter.com"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <script type="text/javascript" src="/_local.js""></script> <link rel="stylesheet" type="text/css" href="/_fyi.css" /> </head> <body> <p></p> </body> </html>
You will get this error:
Error Line 8 column 46: end tag for "meta" omitted, but OMITTAG NO was specified. <meta name="Author" content="FYIcenter.com"> You may have neglected to close an element, or perhaps you meant to "self-close" an element, that is, ending it with "/>" instead of ">".
Note to HTML 4.0 authors, you must close meta elements in XHTML 1.0. This is the opposite of HTML 4.0, where you must not close meta elements.
2007-05-12, 5133👍, 0💬
Popular Posts:
How To Specify Two Background Images on a Page? - CSS Tutorials - Page Layout and Background Image D...
What Is a CAPTION Tag/Element? - XHTML 1.0 Tutorials - Understanding Tables and Table Cells A "capti...
Which bit wise operator is suitable for turning off a particular bit in a number? The bitwise AND op...
What is AL.EXE and RESGEN.EXE? In the previous question you have seen how we can use resource files ...
Which bit wise operator is suitable for turning on a particular bit in a number? The bitwise OR oper...