0

i have used JVectorMap to create a map of spain in HTML/PHP, and im trying to redirect the user once he has clicked on the map, to a custom page that will display info based on the province he selected, to do this im using the onRegionClicked function, and im trying to pass the parameter ‘code’

so far it looks like this

<script>

(function(){('#es-map').vectorMap({map: 'es_merc',onRegionClick: function(element,code,region){document.location.href="http://localhost/proyecto/Web/Provincia/index.html?provincia=<? code ?>"}});
}); </script>

this does paint the map, it does redirect to the page when a region is selected, what i cant figure out is how to send the new php the information of the region the user clicked.

Anonymous Asked question May 13, 2021