Best Doctype and why?
What's the best doctype to use and why should I use it?
you should use the doctype that matches the code you write.
Personally, I use html 4.01 strict. It's the most widely supported by browsers.
xhtml is fine too, though most browsers don't actually parse it as xml, which means (IMO) that there's really not much point. It's nothing more than html 4 with self-closing tags.
Whichever you choose, use the "Strict" version of the doctype (except html5, of course, which has no DTD) and make sure your code follows the rules. That way, you can ensure your markup is being rendered consistently.
Adrian ~ facebook | gist/github
['220.127.116.11','18.104.22.168'] // ip,ip array!
"Take that sticker *off* your hat; you look stupid" --Wil Wheaton
I'm closing this discussion. Please do a search for similar topics before starting a new one.
Here's a long discussion, for example:
Daniel - Freelance Web Design | <?php?> | <html>| Deutsch | italiano | espa˝ol | portuguŕs | catalÓ | un peu de franšais | Ninasoma Kiswahili | 日本語の学生でした。| درست العربية