You are in: home » usability » article

degradability: Technorati blog reaction script

Tags: degradability Technorati Javascript

When I was checking how this websites looked on Internet Explorer 5.5, I noticed the warning icon on the status bar, indicating Javascript errors. There was something wrong with the Javascript DOM navigation, and it was caused by the Technorati script called linkcount, which checks the number of blog reaction to a given post.

The Technorati script tries to follow the basic rules of web degradability:

  • if Javascript is supported, do some actions, i.e. modify the DOM structure of the web page, showing some information
  • if Javascript is disabled or not supported, provide a link to a link to a web page showing the desired information

Unfortunately, the Javascript provided by Technorati fails to meet degradability rules, because while trying to access the DOM structure of a web page, it causes a null pointer exception. The script then stops, a link to a specific Technorati page is still available, as degradability requires, but an annoying Javascript error alert appears.

After checking the Technorati script I discovered the problem is caused by the use of the function getElementsByTagName"*", which returns an empty set in Internet Explorer 5.5. This issue was not taken into consideration, and could have been easily resolved by including a browser check and avoiding old Internet Explorer versions to execute the code.

As far as this website is concerned, I introduced a server-side browser check to avoid old Internet Explorer versions to execute the Technorati script causing annoying Javascript errors. By doing so, smooth degradability is preserved.

referrers Check incoming links to this article, according to Yahoo!.

|

react Send your reaction to this article by email.

|

bookmark Save this article using an online web2.0 service, the bookmark can be priate or can be shared with the rest of the world.

|

print If Javascript is disabled you'll need to use your browser's control to print this pages.