Search code examples
jquerycssimagemap

jquery how to color area dynamically


I have image map like this

<map name="imgmap">
<area shape="poly" coords="63,10,64,38,89,37,91,10" href="#" id="x1"></map>

and how can I color that area dynamically with jquery like

("#x1").color('red')

?


Solution

  • you can try using the maphilight plugin of jquery. it does what you want to achieve - http://davidlynch.org/blog/2008/03/maphilight-image-map-mouseover-highlighting/