Hi,
I really like the Gmap node location block. I however allow multiple locations per node, but only one location comes up in this block. I tried to work around this by making a gmap _view for the node, but never managed to make this work. Now I'm quite new to Drupal but am not scared to get my hands dirty. I've got the devel.module and when I load the node in Dev load view I see that the node has two arrays associated with it, one being "location", and the other being "locations" - is there any way to access these either in the view or in the blocks?
Thanks in advance for your help.
Kehan
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | gmap_location_2a.patch.txt | 17.65 KB | attiks |
| #4 | gmap_location_2.patch.txt | 17.65 KB | attiks |
| #3 | gmap_location.patch_0.txt | 17.3 KB | attiks |
| #2 | gmap_location.module_8.patch | 28.75 KB | kehan |
Comments
Comment #1
astroboy commentedI've changed themodule a bit, to it now displays multiple locations: here is my code (its not formatted cleanly but it works, i'll leav it up to you guys to make a proper patch)
replace function _gmap_location_getlatlon with :
replace function gmap_location_map_add_node() with:
Comment #2
kehan commentedNice! thanks a lot. I've reformatted the code and have attached the patch.
Comment #3
attiks commentedupdate to display multiple locations on map/node and map/node/xxx
WARNING: this will break the special handling of og nodes!!!
change in function gmap_location_node_page
into
change in function gmap_location_map_add_node
into
Comment #4
attiks commentedNew updated patch that will add label (node->title) and click event to the markers
Comment #5
attiks commentedSorry, fix for comment #4, i used
$newmarker['autoclick'] = true;but this will open the text right awayComment #6
fishhaddock1 commentedHello... I have the same issue with gmap for drupal 6.x ... when there are more than one locations in a node, the gmap block does not display both locations. The problem is that those functions in the drupal 5 patch do not exist for drupal 6 version.. the module must have been extensively rewritten??
Comment #7
toledo commentedI would like to have another gmap block with a different location on a different page.
How can I make more than one block with another location for another page/node?
Comment #8
toledo commentedI figured it out. Didn't have the right admin screen up. Dumb.
Comment #10
johnvClosing this very old issue. Please reopen if it is still valid.