Really Solved: Another Common Site Review Problem

Matt Cutts wrote recently of a common site-review problem. Many sites prefer to store links within drop down menus (the “select” element). Unfortunately, this non-standard way of using javascript to link to pages within your site is quite difficult for search engines to spider. (ie: search spiders like GoogleBot have difficulty determining that your javascript code is meant to be interpreted as links).

Here are a few examples:

Luckily, there is a pretty easily solution to the issue. Start by creating a DIV tag with traditional text links inside representing each of the items you would like to appear in your menu. And then just run the javascript I have included below to transform that DIV tag into a traditional drop down menu. I have tested in FF, IE, and Opera without any difficulty.

On a side note, this is also a far more Accessible method of doing drop down link menus. Because the code itself is simple text links, a screen reader will be able to easily understand and interpret that information to a disabled visitor.

Anyway, here is the sample code…

No tags for this post.


  1. Kevin Collins
    May 28, 2008

    Clever tip, thanks!

  2. Vic
    Oct 16, 2008

    Has there ever been an update to this scrip because there about 19 errors when validating with the W3C validator?

    It seems to work and seems to be a nice idea in spite of the errors.

Submit a Comment

Your email address will not be published. Required fields are marked *