Why Use Web Standards?
Tuesday, March 16, 2004 at 5:17 pm | Comments off
I've often had people ask the question
why should I program my site according to web standards? There are many reasons to do so, and I'll try to hit a few of the major ones:
Search Engine Optimization
Search engine optimization is one very important reason to use web standards. Perhaps more important than simply validating your pages, however, would be correct, semantic use of (X)HTML. By using CSS to style your document, you are able to separate structure from presentation. When you do this, your pages not only have visual meaning but also have meaning to non-visual users and programs (such as search engines). Just remember this while marking up your pages: most tags have meaning - be sure what you are using them for conforms to this. It's very beneficial to view your site in a text-only browser such as the lynx viewer, as this will be similar to what a search engine might see. Also, if you are running Mozilla Firefox, you can install the web developer toolbar, which will allow you to disable the styles, viewing your un-styled content, among many other things. It's a must-have, if you ask me.
By using CSS for presentation, you are able to significantly reduce the page weight of your document. This aspect alone could translate into a significant amount of savings on bandwidth for a larger site. Even smaller sites will reap the benefits, as pages will load much faster for users, as once the CSS file has been cached, they will simply need to load your images and (X)HTML, which will be less weighty, once removed of the presentational markup.
Ease of Maintenance
It's an incredible amount easier to maintain a well structured site, as apposed to one that was developed using presentational HTML hacks. Think about it this way, if you were to take over a site from another web developer, wouldn't you much prefer nicely structured code, where the code is self documenting? A <h2>, must be a heading; a <ul>, must be a list. On the flip side you (usually) get to deal with nested tables, non-meaningful, excessive markup, etc.
While having valid code doesn't mean you have an accessible site, it is a good start. Again, by using CSS, you are able to structure your (X)HTML meaningfully, which will help make your site much more accessible. As Tim Berners-Lee has said,
[t]he power of the Web is in its universality. Access by everyone regardless of disability is an essential aspect.
When clean, well-structured markup is used, amazing things can happen. As the CSS Zen Garden demonstrates (previous link), it is possible to completely change the look and feel of the site, without even touching the markup driving it. Need a printable version of the page? No problem.
Not only do web standards help you as the developer, they also help your clients, and their audience. By conforming to today's standards and accessibility guidelines, you can ensure that the content is available to all users, regardless of the device they use to access it. Combine this with bandwidth savings, ease of maintenance, and extensibility – you can't lose!
Comments are automatically closed after 45 days