Skip to content


Destroy Map? #12

sonicparke opened this Issue · 3 comments

4 participants


Is there a way to destroy a map using and event handler? I'd like to be able to dynamically load a map based on user click.


I need this too, i want to reload a new map with ajax.

is this possible ?


my first solution...

first reload wirh ajax
data: {'elid': el, 'typ':'getmap'},
success: function(data){


after this you have a new map....but the lable text is the old. Too fix this i have change

var mapData = WorldMap.maps[]; ---> mapData = WorldMap.maps[]; i have the problem that after hover the color don't switch back.


Everytime you need to update you map you can replace your element hard way :)

$('#vector-map').replaceWith("<div id='vector-map'></div>");
        var $map = $('#vector-map');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.