Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
This is a great module, filling a real need. Thanks.
I'd love to have a "real" google maps formatter, so people could zoom in, zoom out, perhaps get driving directions. That would be perfect for my application.
Thanks!
Comment | File | Size | Author |
---|---|---|---|
#26 | geolocation.tar_.gz | 34.57 KB | andrea.cavattoni |
#24 | dynamic_google_maps_formatter-1115890-24.patch | 8.59 KB | lklimek |
#15 | geolocation.module.files_.zip | 4.52 KB | FreeFox |
#14 | dynamic_google_maps_formatter-1115890-14.patch | 9.45 KB | lklimek |
#13 | dynamic_google_maps_formatter-1115890-13.patch | 9.32 KB | lklimek |
Comments
Comment #1
leschekfm CreditAttribution: leschekfm commentedWe needed a similar functionality in a recent project. The static googlemap is made clickable, so that another browser-tab loads maps.google.com centered on the provided lat/lng.
Our customer has already asked for a 'real' gmap as you suggested. So if you are lucky I will implement this in the near future, but please don't ask when it will happen.
Until then maybe this patch will help you.
Comment #2
wapnik CreditAttribution: wapnik commentedHere is what i used in my theme, a quick solution.
If an iframe is a good idea here, a theme function for it could be useful. And i think user editing the node (entity) should have an option to set the zoom level of the map, map dimensions, ... What about reading this data from the widget map? Some kind of wysiwyg. So the user can resize the map, center it somewhere, zoom and that would be what he can see after saving? Anyway this can be really useful module.
Comment #3
upupax CreditAttribution: upupax commentedsubscribe, this would be a really good feature.
Comment #4
Loikkk CreditAttribution: Loikkk commentedi'm agree with upupax, a good feature to look ahead.
Subscribe :)
Comment #5
andypostMaybe just add a setting to allow colorbox, lightbox integration
Comment #6
Verscienta CreditAttribution: Verscienta commentedSubscribe, I would love to have this feature added. Thank you for all the hard work!
Comment #7
lklimek CreditAttribution: lklimek commentedHi,
I'm working on this topic, hopefully I'll deliver working formatter soon.
Comment #8
andypostgreat, I can review
Comment #9
carl.ben CreditAttribution: carl.ben commentedsub
Comment #10
lklimek CreditAttribution: lklimek commentedHi,
here is my solution for this issue. The patch adds dynamic google map formatter to existing google maps formatter module.
You should apply this patch on latest 7.x dev version.
Please review and let me know if it works.
Comment #11
carl.ben CreditAttribution: carl.ben commentedpatch in #10 seems to work great!
Comment #12
andypostA lot of code-standart issues
Tabs in code :(
why not use Drupal.behaviours?
PS: Please check drupal.org/coding-standards & try dgo.to/dreditor to see tabs troubles
Comment #13
lklimek CreditAttribution: lklimek commentedFixed coding standard issues (at least the most apparent ones).
I don't know if I did fix array braces properly.
Please take a look and explain me how it should look like.
EDIT: sorry it's broken ;). I'll post fixed patch later
Comment #14
lklimek CreditAttribution: lklimek commentedHere is fixed patch.
Comment #15
FreeFox CreditAttribution: FreeFox commentedI tried to patch the latest dev version but it gave me this response:
# patch geolocation.module dynamic_google_maps_formatter-1115890-14.patch
patching file geolocation.module
Hunk #1 succeeded at 16 with fuzz 2 (offset -4 lines).
Hunk #2 FAILED at 37.
Hunk #3 FAILED at 52.
Hunk #4 FAILED at 116.
Hunk #5 FAILED at 135.
Hunk #6 FAILED at 164.
Hunk #7 FAILED at 320.
6 out of 7 hunks FAILED -- saving rejects to file geolocation.module.rej
The next patch would create the file geolocation.module,
which already exists! Assume -R? [n]
Apply anyway? [n] ^C
Files attached in zip file: geolocation.module, geolocation.module.orig and geolocation.module.rej
Comment #16
andypostSeems everything works, let's get more reviews. My +1 to RTBC this patch
@lklimek Now it looks much better, for future check http://drupal.org/coding-standards and try coder module for suggestions
@FreeFox To apply a patch use
patch -p1 < patchname.patch
from module's folder. See http://drupal.org/patchComment #17
lklimek CreditAttribution: lklimek commented@FreeFox: works for me:
Comment #18
derjochenmeyer CreditAttribution: derjochenmeyer commented#15 #16
Or try git and use:
git apply -v [patchname.patch]
See: http://drupal.org/project/geolocation/git-instructions
Comment #19
jagermonster CreditAttribution: jagermonster commentedThe Dynamic google map seems to work well. Can this be commited into project?
Comment #20
FreeFox CreditAttribution: FreeFox commentedThanks for all the help on patching ;)
The patch works like a charm. +1 for commit here.
Good job lklimek!!
Comment #21
lklimek CreditAttribution: lklimek commentedPlease commit.
Comment #22
jm.federico CreditAttribution: jm.federico commentedThanks guys
I just released beta-2, can you confirm it works against that version? If so I'll commit!
Cheers
Comment #23
lklimek CreditAttribution: lklimek commentedHi,
the patch does not apply on latest beta-2.
Comment #24
lklimek CreditAttribution: lklimek commentedHi,
here is a fixed patch.
Please test it with 7.x-beta2.
Comment #25
andypostIs this patch rolled against 7.x-1.x branch?
Comment #26
andrea.cavattoni CreditAttribution: andrea.cavattoni commentedIt's not working properly, check the last lines.
Here the module patched correctly and working...
Let me know if it's working
Bless
Comment #27
andypost@cavax can you provide a patch?
Comment #28
lklimek CreditAttribution: lklimek commented@cavax what's the difference between your version and patch from #24?
I've created a patch from your version and diff'ed it with mine. There are a few fixes I did manually in my version, but the overall patch looks the same.
Do you mean the end of my patch?
This is just white spaces - "\ Brak znaku nowej linii na końcu pliku" means "no new line on the end of file" - I've added new line on the end of file, as described in http://drupal.org/coding-standards#indenting .
Please explain me where the problem with patch #24 is.
Comment #29
jm.federico CreditAttribution: jm.federico commentedHello!
Haven't forgot about this.
There is an issue when showing more than one entity (node) with geolocation fields and dynamic maps where the IDS for each map will be the same, as it only uses the $delta to generate them. Should also use the field or instance ID.
I'm already working on some fixes to that, marking as needs work so I don't forget!
Guys, thanks for all the help!
Comment #30
andrea.cavattoni CreditAttribution: andrea.cavattoni commentedI've tryed out your patch and i got many errors, so i changed it by hand.
yep, i got errors in those lines:
Comment #31
carvalhar CreditAttribution: carvalhar commented#26 module works fine (i was using beta2 and overwrote those files).
But how can i make the marker able to trace a route? Or at least, open the google maps page with this marker?
Comment #32
carvalhar CreditAttribution: carvalhar commentedhey, this #26 module was working fine some days ago but now i get only an empty div:
<div style="width:300px;height:300px;" class="geolocation-map geolocation-googlemaps-dynamic" id="geolocation-googlemaps-dynamic-0"></div>
any reason why this is happening?
thanks
PS: i didn't change this code.
Comment #33
andrea.cavattoni CreditAttribution: andrea.cavattoni commentedTry cleaning the cache or check if the module load the js file.
Are you using Firebug?
Comment #34
carvalhar CreditAttribution: carvalhar commentedit's working today.
i have no idea why it didn't work, my impression was because something changed at google (maybe api) but today it's working again.
i have no idea why
Comment #35
andrea.cavattoni CreditAttribution: andrea.cavattoni commentedThat's drupal 7 i guess :-(
Comment #36
codekarate CreditAttribution: codekarate commentedI applied the patch in #24 against beta-2 and it seems to be working great. Thanks.
Comment #37
nagiek CreditAttribution: nagiek commentedHey there, it looks like this needs a final push.
@cavax can you create a patch for #26? Just to compare with #24.
Comment #38
lysander19 CreditAttribution: lysander19 commentedI also applied the patch in #24 against beta-2 and it seems to be working great. Thanks.
Comment #39
jm.federico CreditAttribution: jm.federico commentedHello everyone
I just committed the Live Google Maps formatter
Latest dev might break stuff if you have other modules integrating with this one, it changes some names on the JS!
If you have you own modules playing with this one, please check the commits messages.
Cheers