Showing posts with label W3C. Show all posts
Showing posts with label W3C. Show all posts

Wednesday, September 8, 2010

Week 3: Web Standards

It is very important to have standards. We have standards of weights and measures. There's agreement on how long a foot is and how much a pound weights. There are industry standards. You don't have to worry about electronic devices only working with one kind of wall outlet (at least not until you go overseas). There's even standards for the weight of yarn.

So why not use standards for the web?

There are already plenty of articles explaining why web standards are good and necessary. The main reasons are:

Maintenance and Production: It is easier and faster, and therefore cheaper, to create a web site that uses standards than to create a site specifically for one browser using proprietary code (or worse, a different site for each browser).

Accessibility: You can make your site more accessible by coding to standards. This is usually stated in reference to disabled users but will also help those hampered by older technology or slow/limited Internet access.

Search Engine Optimization: Other things being equal, a site with valid code is ranked higher by Google than a site with invalid code.

Professionalism and Quality: If you're a web developer writing standard code shows that you know what you're doing. You want to be seen as someone who is current on industry standards, technologies, and best practices. If you own the site then you don't want your site to flat out break in other modern browsers even if it isn't the one most of your target audience.

There are more of course: page weight, re-usability of the code, etc. but these are the reasons I see given the most often. They're also the reasons that both the developer and site owner will care about.

So are there any arguments against using web standards? I didn't really find any articles railing against standards but here are two reasons I've heard not to bother with them.

Tables are easier than using CSS
If browsers would support the multi-column layout module I would just say that this statement is false and move on. But since this is not the case then it may be true in production depending on your comfort level with CSS. But once the site is in maintenance you're in trouble and here's why: the client can't see the table, they only see space.

I can GUARANTEE that eventually the client is going to ask for content to be added someplace that is going to break the template because there is space there. They can't see that putting a wider banner in that cell is going to throw off the spacing for the entire table. They can't see that the change they're requesting is going to require adjusting all of the colspans and rowspans in the table. They only know that they are being quoted/charged an awful lot of money for what looks like a very simple change.

The site has to look exactly the same in every browser so it's OK to make the developer write hacky code.
No.

No, no, no, no, no.

No.

And also no.

I'm going to quote/paraphrase John Allsopp here and say that a site does not have to look exactly the same in multiple browsers because most people don't use different browsers on a regular basis. At worst, for the average non-web designing user, they might be using IE6 at work because they have to and a different browser when they use a mobile device. But no one expects sites to look exactly the same on a mobile device as they do on a computer and since IE6 is not a modern browser there can't be a reasonable expectation for things to even work in it, much less look the same as they would in IE8 or FF 3.x.

Yes, I did say earlier that you don't want your site completely broken browsers other than the one used by the majority of your users but there's a difference between the template being broken and something being 5 pixels farther to the left in IE than it is in FF.

Side Note:
OK, how ridiculous is this? Apple has an HTML5 showcase but blocks you if you try to view the demos in anything other than Safari. *facepalm*
Found via an article in InfoQ.

Wednesday, September 16, 2009

4th Week of Class: Storage Options

I need to correct something I said about the assigned weekly in my first post. I said that the required weekly post would be about "topics discussed in class or reading material". In fact, the requirement for the weekly post is that it be about something we learned that's related to our Internet Technology classes.

This news came the RSS feed for the W3C, one of 25 I subscribed to through Google Reader as part of last weeks assignment.

The Rich Web Client Group recently released Working Drafts: one for Web Storage and one for Web Database. (Learn about W3C Activities) Each is related to storing information on the Internet.

The Web Storage Draft defines an API that will hold information similarly to how a cookie does, in key-value pairs, but seeks to overcome some of the problems and limitations that cookies have. The draft gives a couple of examples of the problems that can happen with using cookies and I have had the issue they point out in the airline ticket example happen to me before.

The Web Database Draft defines an API for adding and accessing information in databases. This draft shows some example code at the beginning. It never names a language so maybe they intend for it to be language independent.

Each will be dependent on HTML5* and WebIDL, neither of which are finished yet. I guess I shouldn't expect to see either finished anytime soon.

*The review comment form on this page is nifty.