This is a sandbox project, which contains experimental code for developer use only.
Create a simple way to display maps with the jquery jVectorMap Plugin.
I had to do a lot of hardcoding for using this Plugin I will think about makeing this easier in the future...
What is my use case
I had to develop a tool which displays demographical data. In this project we need a map to provide a comfortable region chooser for the user.
Our main problem was that we needed other maps than those coming with jVectorMap. So we had to create our own mapdata. (This was made by hand because we didn't have much time.) I have some other "map" interfaces that need to become a jVectorMap and I really don't want to to this again by hand.
What means create a custom map by hand
- Get shapefiles from the area you need the map for
- Load them into TileMill
- Export the map as SVG
- Extract the path data from the SVG to get a jQuery data object like it is needed by jVectorMap (I used this tutorial http://matthiasschuetz.com/jquery-tutorial-svg-daten-mit-jvectormap-dars...)
What are my plans for a module
At the moment I am looking for a lib that can import shapedata into the Drupal db. The next step would be some code that can create the jVectorMap data from the geodata in the db.
If I got that we could have views and/or tokens to display a jVectorMap at any place in our site.
If you got some ideas about that topic drop me a note in the issues or use the contact form...
What's going on...
I was contacted by brockfanning if we shouldn't start with a basic module that can show the maps that come with jvectormap. A good idea I think. We are disscussing how a UI should look and what are generic use cases for such a module could be at the moment.
If you got good ideas what you could use the module don't hesitate to share it and post a feature request.