Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it important for a page to be standards compliant even if it works fine?

I have a html page that has more than one head and body. The first body says "loading" before the rest of the head with javascript and the other body loads. The javascript then deletes the first body before showing the whole document.

My friend told me this is not standards compliant. But the page works fine on Internet Explorer and in Firefox too.

Is it actually important to be standards compliant if the page works fine?

~~ edit ~~

thanks for all the help, i'll make it standards compliant like suggested.

like image 465
captainandcoke Avatar asked May 12 '11 23:05

captainandcoke


2 Answers

I recommend being standards compliant for the following reasons:

  1. If a page is standards compliant, your browser doesn't have to do unspeakable voodoo to try and get your page to render. People like faster page loads
  2. Which also includes Google Bot. If Google Bot doesn't have to tear its robotic hair out it becomes happier. While there are other things that need to be taken into consideration, it's good to have this base covered
  3. When you're dealing with DOM manipulation through JavaScript, non compliant html/xhtml sometimes produces weird results that lead to an annoying amount of time spent debugging
like image 145
onteria_ Avatar answered Oct 31 '22 22:10

onteria_


Think of it like duct-taping your broken car muffler. Sure it works now, but for how long? Web standards are there for a reason, and browsers follow them the best they can. If you follow the standards, then you can be assured that your site will work for quite a while. If not, you might be relying on some bug or quirk in the browser, which might get fixed and leave your site looking like garbage.

Follow the standards; you won't regret it.

like image 34
Blender Avatar answered Oct 31 '22 20:10

Blender