A document in XHTML 1.0 standard must be strictly conformed or with other words it must meet all the criteria written below:
- It must follow the rules defined by one of the three DTDs available which must be declared at the beginning of the document (before root element)
- strict.dtd
- transitional.dtd
- frameset.dtd
- The root element is always <html>
- The root element must contain XML namespace <xmlns> declaration
- DTD subset must not override any parameter entities in the DTD
It is also suggested but not mandatory to use XML declaration with the character set at the beginning of the document.
XML Declaration:
<?xml version="1.0" encoding="UTF-8"?>
Document Type Declarations:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
Namespaces:
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
Together:
<?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 xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
Comments
No comments have been made yet.
Please login to leave a comment. Login now