1. Computing

Discuss in my forum

Jennifer Kyrnin

Poll: Do you validate your HTML code?

By May 3, 2007

Follow me on:

One of the best ways to solve problems on Web pages is to validate your HTML code before you post it.
check yes
Image courtesy yarranz from StockXchng #426123.
And yet, I know that most people (including myself) don't do it. I have to admit that I tend to only validate pages I've written if they don't show up correctly. And before you ask, yes, I know that the HTML on the About.com pages does not validate. But your first response when you have a page that isn't working as you expect it to is to validate the HTML and CSS. In fact, if you write to me for help, that's what I'll tell you to do. ;-)

Do you validate your HTML code?

Has validating helped you? Or has there been a situation where validating your HTML or CSS caused you more problems?

View Results

May 3, 2007 at 4:30 pm
(1) Jason Champion says:

ya.. there have been some issues with validating. Especially when using javaScript. I try to avoid the use of javaScript when possible, but sometimes when there are elements using CSS to hide them, and a javaScript function to determine when to show them, it will not validate because of multiple IDs for the same tag using the get element by ID. Hope that makes sense….

May 3, 2007 at 5:30 pm
(2) Dazza says:

100% validation is almost impossible due to the ever increasing changes made and the systems used by most sites.
I use a basic PHP/HTML/CSS system whereby most html is generated or stored in Databases and if I try validating most of the time it will give between 20 and 50 validation errors on the norm, yet I have minimal problems.
The problem is most errors are things like invalid entities, attributes not specified, unknown types etc.
The validation services are almost useless for most modern ajax or script based sites.

May 3, 2007 at 6:40 pm
(3) Jason Champion says:

Ya.. I agree. Although W3′s validation tool is pretty good, and Dreamweaver’s tool is pretty decent, neither one are perfect when it comes to validating content that is based on dynamic output. There have been times where it would not validate, but I knew for a fact that it was valid xHTML. So I just grit my teeth knowing that I don’t get to put the cute little valid xHTML gif on the site :)

May 3, 2007 at 6:42 pm
(4) Jason Champion says:

ps – I usually just copy and paste the source of the page’s results into W3′s validator to make sure.

May 3, 2007 at 9:35 pm
(5) dean says:

The web developer extension for firefox makes it easy to quickly validate pages. One click validation for html, local html, section 508, wai, css, feed, or links.
There are several other very useful tools in this extension.

May 4, 2007 at 11:08 am
(6) Anna Belle says:

Great question! I answered with #2 (sometimes), but really the choices didn’t cover my usual practice. I expect I’m not alone in this practice. It is to validate redesign drafts and template pages scrupulously, and thereafter validate sporadically.

May 4, 2007 at 11:18 am
(7) Jason Champion says:

Dean… funny thing. I just downloaded that tool, then ran the css validation on the Web Developer Extension’s download page and the home page, and it returned errors. Not a good sign.

May 4, 2007 at 11:57 am
(8) Jason Champion says:

well… I decided to send them an email. Apparently, they’re using CSS 3.

May 4, 2007 at 3:55 pm
(9) Lori says:

I do try and validate my HTML and CSS for every page. Some small things, like Google Analytics code, can prevent 100% validation. Frustrating!

May 4, 2007 at 6:28 pm
(10) dean says:

Jason… I think you’ll find the tool to be rather awesome after you use it a while. Even though the css validator returned errors on the home page and download page, I bet it only took you a few seconds to find out.

May 8, 2007 at 7:47 am
(11) Howard says:

I installed the Firefox HTML Validator 0.8 validation extension. I use it, and it catches lots of errors, but I’ve seen it can miss errors. It just doesn’t catch them all. So, do I cut and paste into W3 or what, as I’m left wondering if everything is caught.

May 8, 2007 at 7:51 am
(12) Roc says:

We validate our web design customers html and CSS code. But our own sites only get a quick glance at the html and CSS validated. Kind of like the doctors patients are well while his family is sick.

May 8, 2007 at 9:13 am
(13) Jennifer says:

Always!! Every page. Helps catch any errors I may have missed and feels good knowing I didn’t take any shortcuts in design. However, I do NOT stick that little W3C Validated logo on my page…just plain tacky if you ask me. If I feel the need to brag about my oh so validating site I just note it inconspicuously on the bottom of the page. I also validate my CSS as well. W3C and DreamWeaver together will catch most errors.

May 8, 2007 at 2:23 pm
(14) Bryce says:

Because I use php include statements, and a lot of plain html code is stored in MySQL to be inserted when a page loads, I’ve found validation to be pretty annoying.

On the other hand, it has proven somewhat useful in reminding me of XHTML standards, such as the javascript tag not being enough information to tell XHTML that it really *is* javascript.

I guess for some people (and XHTML) you need to say things at least twice before they’ll hear you.

May 8, 2007 at 3:07 pm
(15) AngelEyes says:

I make every effort to write valid code. I use HTML-kit to write my code and use HTML-tidy to catch the most obvious errors. After I am satisfied with the code. I load it using Firefox to see the results. Firefox has many developer tools that make validation easier. Unlike Jennifer I think displaying the W3C logo is a service to web users. It gives them a chance to check the page for themselves. It also introduces users to the W3C.

May 8, 2007 at 5:31 pm
(16) Jason Champion says:

I have to agree with Jennifer that the logos are tacky. You can always use a simple link to validate your code on W3C. However, you can always design your own image link for validation that better suits your site… at least, I don’t think there’s a law against that :) Afterall, I’ve seen plenty of them out there that that other people have done and do not exist on W3′s list.

May 9, 2007 at 1:38 pm
(17) Jennifer Kyrnin says:

Bryce, you said:

I guess for some people (and XHTML) you need to say things at least twice before they’ll hear you.

I’ve found that 2 times is the minimum – and I’ve been told that for memory purposes you have to hear something like 3-5 times before it sticks. So I repeat myself periodically. :-)

May 11, 2007 at 1:53 pm
(18) Paul M. Van Dort says:

Validation helps to insure that your page will work in all the current browsers. I use FireFox’s automatic error check on every page I look at, but on the pages I write, I go one step further and validate using the W3C validation service.

I have a client whose competition’s site shows 45 errors on the home page. One of those errors is preventing the major information area from showing in FireFox. So that page (and all the rest) is not available to 32% of viewers (according to current statistics from the W3C).

If only they had validated their code, or at least checked their work on the current browsers, they could have avoided losing viewers.

A little extra effort goes a long way.

January 22, 2008 at 11:56 am
(19) jonathon says:

i still get errors when i have validate my html page on the validate page, do i really need to validate my html files, if they display ok.

January 22, 2008 at 2:24 pm
(20) Jennifer Kyrnin says:

Jonathan: Validating your site is up to you. And I would say than 90% of sites out there are never validated. However, if you then ask a question about how to get something working on your site, chances are most people responding will suggest that you make sure that it’s valid first – to rule that out as a cause of the problem.

December 25, 2008 at 9:59 am
(21) Bill Williams says:

I validate all pages…sort of. I view my pages in Firefox, Netscape, and IE. I usually have to make adjustments to accommodate IE. I really, really hate IE.

April 26, 2010 at 8:35 am
(22) w3cvalidation says:

Nice information, I really appreciate the way you presented.Thanks for sharing..

Leave a Comment

Line and paragraph breaks are automatic. Some HTML allowed: <a href="" title="">, <b>, <i>, <strike>

©2014 About.com. All rights reserved.