Problems with plugins in Jvector Map

Hope someone can help me. I found this nice jQuery plugin to display vector maps on our intranet, but I cannot create HTML code to make it work.

http://jvectormap.owl-hollow.net/

I would be grateful for your help or guidance.

Thank you, Tony

+4
source share
2 answers

You may have forgotten to set the size of the container inside which you want to place the card. This should work:

<!DOCTYPE html> <html> <head> <title>Test</title> <link rel="stylesheet" href="jquery.vector-map.css" type="text/css" media="screen" /> <script src="jquery-1.6.min.js"></script> <script src="jquery.vector-map.js"></script> <script src="world-en.js"></script> <script> $(function(){ $('#map').vectorMap(); }); </script> </head> <body> <div id="map" style="width: 600px; height: 400px;"></div> </body> </html> 

I will add width and height options in the next version

+3
source

You must install your card. whose name is on top of map.js. You may have forgotten

 $('#map').vectorMap({map: 'europe_en'}); 
+1
source

All Articles