Small Business Consulting Services, Raleigh North Carolina
     
Home Blog Web Traffic & SEO Save headaches and validate markup
Save headaches and validate markup PDF Print E-mail
Written by Jason Bostic   
Thursday, 27 March 2008 11:24

Many people underestimate the importance of valid markup. There are rules for proper HTML and XHTML, and there are reasons for those rules. WYSIWYG layout editors made many web designers (including myself) lazy. We were rightfully worried about what the page looked like, but often neglected the importance of what the code looked like. In fact, Internet Explorer shares much of the blame as oftentimes web developers had to purposefully write invalid markup as Internet Explorer didn't (and in some cases still doesn't) render proper code properly. But when you neglect your markup, eventually your web page itself will fail.

I'm putting the finishing touches on a new website that I hope to announce here over the weekend. Yesterday I spent a good bit of time working on some contact and ordering forms for the site, stylizing them with CSS while adding some tooltips and input validations. I wanted to get home and cut my normal cross browser tests short, only running the form on various versions of Firefox and Internet Explorer on a PC. Everything looked great, further testing could wait.

At home I opened the site up on our Mac Mini. Guess what, the form looked awful. What rendered beautifully on a cheap Dell laptop in Firefox looked horrible in Firefox on the Mac. So I launched Safari and Opera and a few other smaller browsers all with the same results. I opened the PC laptop again and typed in the URL. It still looked good in IE and Firefox, but the Windows version of Safari rendered the same mess that I saw on the Mac. Why did the form look so great in IE and Firefox on a PC, and look awful in Windows Safari and all browsers on my Mac? Safari is an Apple product, maybe its Apple's fault?

Not a chance. It wasn't a bad Mac or bad software that caused the problems, it was bad code. A quick trip to the W3C Markup Validation Service (http://validator.w3.org/) pointed out that I had the space in a BREAK tag in the wrong place, forgot to close a PARAGRAPH tag and was missing a quote. Those typographical mistakes in the form caused 20 markup errors to be reported. Safari in Windows as well as the Mac browsers were rendering the page perfectly... I just didn't write the markup well.

It happens. We all make these mistakes. Sadly, many so-called web developers don't take the time to test for cross browser performance or functionality. Many don't bother to see if their code is valid or if a page renders as well in different platforms or browers. But they should. For years people were writing exclusively for Internet Explorer, often with neat little layout editors that wrote your markup for you. And many people still do. But as Firefox and Safari gain marketshare in the browser space, and more educational institutions, businesses and consumers switch their Windows boxes for Macs, the browser landscape is changing and its not acceptable to write lazy code any more.

It never really was really, but it was easier to get away with it. Sadly too many people still do.

We all make the mistakes from time to time, but does your web developer take the time to check? Do they care? When they find a cross browser problem as we all invariably do, will they take the time to fix it or even know where to look? If not then you need to be the one looking, for a new web developer who cares about your business and the experience of your customers. You don't get a second chance to make a first impression... if their first impression isn't in Internet Explorer or on a PC, with a badly written site, you might as well consider that customer lost.

Last Updated ( Thursday, 27 March 2008 14:09 )
 

Sponsored Links