Sie sind auf Seite 1von 1

XHTML Quick Reference www.kellermansoftware.com Free Quick References and .net components.

Example XHTML File

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN“ "http://www.w3.org/TR/xhtml1/DTD/xhtml-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml“ xml:lang="en" lang="en">
<head>
<!-- Write all tags in lower case. Case of Content or attribute values does not matter. -->
<title>Insert Title Here</title>
<!-- This Content Type tag is essential. -->
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<meta name=“Description” content=“Insert Description Here”>
<meta name=“Keywords” content=“Some, Keywords, Here”>
<link rel=“stylesheet” type=“text/css” href=“http://www.myurl.com/mystyles.css” title=“webstyle”>
</head>

<body>
<!-- Quote all attribute values -->
<hr width="75%" size="7" />

<form action="http://www.myurl.com" method="post">


<!-- All attributes require values -->
<input type="checkbox" name="shirt" value="medium" checked="checked" />
</form>

<!-- Empty tags must close themselves by including a space and a slash at the end of the tag -->
<br />

<!-- Double dashes can occur only at the beginning and end of a comment. Use = instead for separators -->
<!-- =============================================================================== -->

<!-- Encode the ampersand, less than sign, and greater than sign. Hex values must be lower case -->
<p>Math &amp; logic prove that 1 &lt; 2 &x21;</p>

<!-- Use this code below to self validate the XHTML -->
<p><a href="http://validator.w3.org/check/referer">
<img src="http://www.w3.org/Icons/valid-xhtml10" alt="Valid XHTML 1.0!" height="31" width="88" />
</a></p>

<!-- Use this code below to self validate the CSS -->
<p><a href="http://jigsaw.w3.org/css-validator/">
<img style="border:0;width:88px;height:31px" src="http://jigsaw.w3.org/css-validator/images/vcss" alt="Valid CSS!">
</a> </p>
</body>
</html>

Special Notes
* XML Prolog can cause pages to display blank. Do not use this: <?xml version="1.0" encoding="ISO-8859-1"?>
Instead use a Content-Type element: <meta http-equiv="Content-Type" content="text/html; charset= ISO-8859-1" />
* All XHTML tags must be properly nested.

Web Standards References Validation Services Special Notes


XHTML Reference XHTML Validation Service * Dreamweaver MX can
http://www.w3.org/TR/xhtml1 http://validator.w3.org/ produce valid XHTML.
* Dreamweaver also has a
CSS1 Reference Section 508 (Accessibility
CSS Validation Service
http://www.w3.org/TR/REC-CSS1 validation)
http://jigsaw.w3.org/css-validator/ * Front Page produces web
CSS2 Reference pages that are viewable
http://www.w3.org/TR/REC-CSS2 HTML Validator only in IE.
http://www.htmlhelp.com/tools/validator/
W3 DOM
http://www.w3.org/DOM/DOMTR#dom1 DOM Browser Sniff
Link Checker
if (!document.getElementById)
http://validator.w3.org/checklink {
ECMA Script (Standard version of Javascript)
http://www.ecma.ch/ecma1/STAND/ECMA-262.HTM window.location =
Clean Up & Convert HTML to XHTML "http://www.site.com”
http://tidy.sourceforge.net/ }

Das könnte Ihnen auch gefallen