View Full Version : CSS Rollovers and SEO

04-10-2009, 04:25 PM

I have a client that would like to use images for links, with rollover states. The way that I usually do this is by using "Pixy" style rollovers, where I combine two images into one and then just switch the background position using CSS. However, it would seem this isn't as good for SEO as I wouldn't get to use an alt tag. Would you recommend using javascript and separate images for the rollovers to gain the advantage of alt tags?

04-10-2009, 04:28 PM
I would recommend having content worth of seo and not worry about anything else. Google would ignore this anyway, or at least consider it trivial.

04-10-2009, 04:29 PM
If your anchors have display:block; style, then you could add the link text inside your anchor tags as normal and then apply a big negative text-indent, say


<a href="mypage.html" class"mylinks">My Page</a>, which would optimise to an extend.

PS: Your menu may create some accessibility issues for those who have "blocked the images"/"no way to get images"