Writing Code

XHTML

Declare a Document Type

Per HTML and XHTML standards, a DOCTYPE (short for “document type declaration”) informs the validator which version of (X)HTML you’re using, and must appear at the very top of every web page. Valid HTML/XHTML is important for creating documents that are accessible. DOCTYPE declarations are the key to compliant web pages. Your page won't validate to W3C standards if the proper doctype is not declared.

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

Some Basic XHTML Rules

 

 

 

Language Declaration