Wednesday, 18 September 2013

DOCTYPE-The beginning of all xhtml documents.

The Document Type Definition DTD is used to define the set of markup declarations that define the kind of SGML family markup language you use in your website design.

The different DTD that can be used under different set of user requirements.

For XHTML version 1.0 we have 3 different DTD definitions.
  1. XHTML 1.0 Strict
     <DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "">  
  2.  Transitional
     <!DOCTYPE html PUBLIC "-W3C//DTD XHTML 1.0 Transitional//EN" "">  
  3. Frameset
     <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "">  
For XHTML version 1.1 we have 2 different DTD definitions
  1. XHTML 1.1
     <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "">  
  2. XHTML Basic 1.1
     <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.1//EN" "">  
For XHTML version 2.0 we have
  1. XHTML 2.0
     <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 2.0//EN" "">  
For HTML 4.01 we have 3 different DTDs similar to the XHTML 1.0
  1. Strict
     <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "">  
  2.  Transitional
     <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "">  
  3. Frameset
     <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" ""> 
Next comes the famous HTML5 
Though not a standard yet, but still has a small and simple DTD declaration to it


Yes,that is it.

Why all these different types of DTDs? 
What do they mean? (Strict/Transitional/Frameset/Basic/loose)

Watch the next post.
Post a Comment