jamietre/ImageMapster — Issue #31: Different colors
Author: ic3y
Created: 2011-11-14 12:55:18+00:00
State: open

I really like your script, but my JS knowledge is too much limited to make it do what i want with it. Perhaps you could help me out.

I have a page with an image of a world map that is connected to a database. In the database there is data (percentage scale 0-100) for each and every country for multiple subjects. I'd like to divide the world countries into five different colors, depening on the data. So for example if the US is 80%, the color will be dark blue. If Canada is 50% the color will be light blue and so on.

Now everything works, but i am not able to make a startcolor per country. Any thoughts?

e.g.

key: "US",
toolTip: $('

Content'),
fillColor: '000000',
stroke: false