|
Recent
Articles |
RSS Feed Tips To Help SEO RSS feeds are a great communication medium, and when properly managed, web feeds can bring in significant Internet traffic. RSS feeds should contain compelling themed content with episodic titles that are united in common broad theme. Use RSS feeds...
XML Code Comments: What, Why And How During the years I've seen a lot of different ways of commenting code - some good and some bad. My personal favourite way of commenting code is by using the XML comment feature of C# and VB.NET, but the important part of commenting code is not how...
ColdFusion / XML Query Style At one point or another, whether it's an enterprise level website, or one of your own, you're going to have the burning desire to see how you can take advantage of what XML can do for your applications. I work...
Spry: Custom Columns A few days ago I posted a link to a few new Spry demos including one that shows how to build custom columns in Spry. This is a pretty cool feature so I thought I'd whip up another demo so folks can really appreciate how handy this is. The idea is simple: You tell...
XML Country List File Today, I had to bind a list of countries to a drop down list in ASP.NET 2.0. I wanted to use an XML file to store the countries. There are more than 200 so there was not way I was going to hard code them in the HTML. I have done this many times before, but never from an...
XML And SAP Business Connector Integration Corporations are always in search of the most effective mechanism for both acquiring and selling goods as well as services at very minimum total cost over the Internet. The Business Process Connectors for SAP systems...
Adding Your Blog To IE7 Search Providers Internet Explorer 7 comes with build in web search from the toolbar, just like Firefox have had for years now. The cool thing about it is that you can offer your visitors to add your blog search to the different providers like MSN Search and Google. That's because IE7...
Debate: Full Or Partial Feeds? One topic of debate that has gained attention in the blogging community is the choice between using full or partial RSS feeds. For the uninitiated, RSS (RDF Site Summary or Really Simple Syndication) is a set of web feed configurations that are spelled out in XML code.
|
|
|
02.19.07
The Real Selling Point Of XHTML
by
Mads Kristensen
Some years ago there was a lot of fuzz about the importance of the W3C XHTML standard.
I've always been a firm believer of the standards and built every website to comply with them. But why?
Very brief history
The standards have made a huge difference historically speaking, because they helped eradicate browser specific mark-up to such a degree that it today doesn't really matter if you use Opera, Firefox or IE. The same is true with the CSS standard to some extend. The next releases from the browser manufactures will be even more compliant until they reach ~100% and that is fantastic from a web developer's point of view.
Strange selling points
Over the years I've heard a lot of strange selling points about XHTML, mainly from smaller web design companies. They tell you why they use XHTML and why it is a future proofing feature of their work. Some of these selling points make sense in theory, but is out of touch with the real world. Below are four of those selling points and why they don't matter as selling points for XHTML.
XHTML is XML
One of the biggest lies about future proofing using XHTML is the argument that XHTML is XML.
Because XHTML basically is XML documents it means that those web pages are machine-readable using XPath.
Today, we know that we cannot rely on the XML validity of XHTML documents in general and therefore don't see them as XML documents suitable for machine parsing. The DOCTYPE tells you one thing, but the validator disagrees. Normally we use regular expressions to parse XHTML documents when we instead could have used XPath according to the selling point. But of course, we can't.
Mobile platforms
Another great selling point is that XHTML web pages are readable on mobile devices or take very little modification to be. That was not correct 5 years ago and it still isn't even though mobile browsers have become much richer such as Opera Mini and Pocket IE.
XHTML is more readable on mobile devices - not because it is XHTML but because its mark-up is simpler. The problem is that in the year of 2007, mobile devices are still terrible at CSS and JavaScript. The autopostback feature of many ASP.NET controls works only in Pocket IE because it uses JavaScript. Changes are that your existing XHTML website does not work on mobile platforms because it is filled with JavaScript and CSS.
The newest standard
XHTML is the newest HTML based standard so it will be easier and cheaper to upgrade to the next standard when it arrives. That's also a good one. XHTML 1.0 is from January 2000 and has had a small upgrade to XHTML 1.1 a couple of years later. What is the average lifespan of a website compared to the lifespan of a W3C standard? I'll bet that the website changes before a new standard arrives and even though it arrives before, which browsers will then be ready to fully support it and will it be backward compatible?
Yes, XHTML is the newest standard and it will be cheaper to upgrade, but it doesn't carry much weight in practice and thereby isn't future proofing.
Separation of content and style
The XHTML 1.0 and the CSS standard made an impact because it let to the separation of content and style. It is easier to maintain a website when the style and content is separated in different files. The same goes with JavaScript. It makes the pages smaller and quicker to download. The funny thing is that you can do that too in HTML 4.01. Smart yes, future proofing no.
The real selling point
So what is the selling point really? If it isn't the machine readability, the mobile rendering, the newest standard or the fact that you can separate content and style, what then?
The reason I use it is because it has better cross-browser support in the DOM and it look prettier, but is that really a general selling point for an entire standard today? I'm not surprised by all the web developers who don't care about XHTML when the selling point is so hard to find.
Comments
About the Author:
Mads Kristensen currently works as a Senior Developer at Traceworks located
in Copenhagen, Denmark. Mads graduated from Copenhagen Technical Academy with a multimedia degree in
2003, but has been a professional developer since 2000. His main focus is on ASP.NET but is responsible for Winforms, Windows- and
web services in his daily work as well. A true .NET developer with great passion for the simple solution.
http://www.madskristensen.dk/
|