Search code examples
cssimageimagemap

Changing the colour/transparency of a div on rollover or using an imagemap


I have a map which is one image. I need to have five hit areas on that image and when you rollover one of those areas, that div / part of the image / imagemap needs to go grey.

I don't want to use multiple images - I want to keep the map as one image.

Can anybody please help me - I've been searching most of the day for a solution and can't find one.

Thanks in advance.


Solution

  • The most straight forward solution is probably an image map using maphilight. You can find an example there with the code available here.