JQVMAP Reset all settings

224 Views Asked by At

i am using the map to select countries via a button. once clicked the countries are highlighted.

$(".mp-cyprus-A").click(function(){

    $('#vmap').vectorMap('select', 'us');
    $('#vmap').vectorMap('select', 'gb');
});

There are ways to set the countries colors, but not using the color range only same color for everyone. Do doesnt work for me.

I have other buttons which select other countries and i require restting the map back to the original state before new countries are highlighted.

Or is the only option to destroy and rebuild the map?

1

There are 1 best solutions below

0
happycoding On

Use JvectorMap for larger libary.