Hi,
My plan is to get GPS data (lat/lon) of track from custom database table and show it on website as Google Map. Map would be related to one specific node.
I'm Drupal newbie and I've been trying to learn things by installing different modules and just testing how they work. I've tried GMap, Location, Track, Whereis etc... All of these are very cool modules!
Track module seems to be almost everything I need but there is no way to get data dynamically from database, I guess..?
In ideal situation, when adding new node, user could select specific dates, pull GPS data (between those dates) from database, see available routes and make the selection.
What would be the best practice to achieve this? Combining current available modules somehow or writing custom module ...?
I already tried to do a very simple custom module that reads data from my GPS table (based on selected dates defined in node) and draws a track map using GMap module. Now I'm just wondering if I should continue with my own module or am I trying to reinvent the wheel here...?
Any comments, ideas are much appreciated! Thanks in advance!
Comments
trackfield
You could use a combination of trackfield and a small custom module for that.
All you'd have to do was write a small add-on module that would fetch the details from the DB for each node and present as a string back to the main module for saving.
Have a look:
http://drupal.org/project/trackfield
Specifically, download this and have a look at one of the 'other formats' modules that are included (like trackfield_gpx for example).
It should be relatively easy to hide the 'track data' and types inputs.
Although... you could forget about that and just write a module with your own add on content field and have it pull data dynamically from the DB, format into a gmap macro and present. Have a look at the trackfield_gmap.module as this is pretty much what it does.