Sunday, November 18, 2012

Answers > What Are the Benefits to Having Valid Xhtml?

What Are the Benefits to Having Valid Xhtml?

by nForms on June 17, 2012

Are there any benefits to having valid xhtml on your pages, besides knowing that all of your tags are closed and all of your special characters are escaped?

And to go a step further, if you can answer this - is there any benefits to using a particular DOCTYPE, other than certain attributes are available to you?

Tags: , , , , ,

Similar XForms | XML Posts

{ 3 comments… read them below or add one }

jonathanlks March 25, 2011 at 9:34 pm

Having Valid XHTML if your mainly catering to computer user’s with browsers like IE and Firefox doesn’t really matter too much. These browsers can pick up any errors you make and correct them for you.

However more simplier browsers like those on Cellphones or what not, might not have the power to correct mistakes, having Valid XHTML means they don’t need to try and horribly fail.

Having a specific DOCTYPE, other than having certain tags available or not available to you really doesn’t matter on webpages.

Colin March 25, 2011 at 9:34 pm

Outside services require a valid doc. These may include…

RSS, Widget creators, mobile services, and the many dozens of XML-based Web 3.0 web services that will pop up in the next few years.

Mr. Fern March 25, 2011 at 9:34 pm

Interoperability and continuity. Different browsers, different operating systems, different media types, valid code helps keep all things the same among them. CSS encounters these issues as well, despite validity. Different DOCTYPEs serve different causes, browsers know what to expect and how to handle the code. Severe displays of this are the lack of a doctype and how different IE will render a webpage in comparison to FF.

Previous post:

Next post: