Wednesday, June 18, 2008

DOCTYPE for XHTML documnets

Recently I faced a problem while playing with dojo tree.The DnD within the tree was not functioning properly.I spent all the day to fix the problem and was getting frustrated as I couldn't figure out what was I missing. At the end of the day I suddenly could remember some buddy on the net wrote that DOCTYPE tag that we often overlook while beeing busy with some other stuffs is very important while playing with DHTML/XHTML documents.
So if you are a good web2.0 player be sure you are not missing your DOCTYPE tag on the very first line of you page :)
A sample DOCTYPE tag should look like:
PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

Reference:
http://www.w3schools.com/tags/tag_DOCTYPE.asp
http://www.w3schools.com/Xhtml/xhtml_dtd.asp

No comments:

Post a Comment