|
||||
|
|
Converting 80,000+ Web Pages to Valid XHTML
By Philip C. Paradis Let's face it: Web standards matter these days (more on why shortly). If you're like many webmasters, you've spent a lot of time developing your website's content. You may or may not have been paying strict attention to (X)HTML standards along the way, and now you'd like to straighten things up a bit. Unforuntately, unless you've used a single standards-compliant CMS (content management system) throughout your site's entire existence, the prospect of dealing with the HTML mess you're facing is probably more than a little daunting. That's okay; I'm going to show you how I converted ClassHelper.org from buggy (to put it mildly) HTML 4.01 code to XHTML 1.0 Transitional pages that validate cleanly with the W3C validation tool. Yes, that means all 80,000 plus pages of content on this site. Why are Web standards important?Visitors to your website will be using a variety of browsers, some of which may not even be running on general purpose PCs. All web browsers exist to do the same thing: render textual content into a format that human beings can easily consume. In pursuit of this goal, browser vendors have taken a variety of paths. Historically, different browsers have supported different extensions to HTML standards, resulting in pages that break when viewed in competing browsers. This is a sad state of affairs that can't be tolerated by any webmaster with a desire to reach the widest possible audience. Web standards define a common set of rules that browser vendors conform to (to various degrees) when rendering pages, with the goal being to provide a "guaranteed safe" standard to code to. In theory, all web browsers should render standards-compliant code the same. In practice, this isn't always the case, but browsers are getting better at it with each new version. Web browsers aren't the only user agents (programs) that depend on standards to read your content. Search bots from the likes of Google, Yahoo!, and MSN comb the billions of pages on the web to index the Internet as we know it. How well your pages rank in search results depends in part on how easily search bots can understand them; compliant pages stand a much better chance of ranking well than those that resemble "tag soup." This has a direct affect on your bottom line as a webmaster, and should be plenty of motivation to get your house in order when it comes to standards.
The Importance of Backups and VersioningBefore we get too far along, this is a great time to remind you of the critical importance of having good backups. Aside from the risk of your hosting company disappearing overnight, your server catching fire, or a meteor vaporizing your data center, performing wide-scale modifications to live web pages is a really bad idea. There's no recovering from big mistakes without backups. Additionally, your visitors are likely to get pretty annoyed by large groups of pages that render improperly due to "work in progress syndrome." It's a good development practice to maintain a completely separate version of your website for development purposes, migrating changes to your live (or "production" in software parlance) site when you're ready to show your work to the world. Continue: Getting Started With XHTML Conversion
|
|||
| All contents Copyright © 2007-2009 ClassHelper.org®. Please see our Privacy Policy. | ||||