Whenever I try to overlay data, I get the browser error "gmap-auto1-gmap0" - clicking OK to the error loads the map and overlay as expected.

Any ideas what could be up?

CommentFileSizeAuthor
#4 gmap_overlays_remove_alert.patch685 bytesgeodaniel

Comments

Anonymous’s picture

Version: 5.x-1.x-dev » 6.x-1.x-dev

Seems like debug code was checked in.

Edit the file js/overlay_geoxml.js so that the line

alert (obj.map.getContainer().id);

reads

// alert (obj.map.getContainer().id);

or remove the whole line entirely.

HTH,
dziegel

wessex’s picture

Thanks dziegel, I'll give it a try!

wessex’s picture

It worked!

Thanks ever so much :-)

geodaniel’s picture

Status: Active » Needs review
StatusFileSize
new685 bytes

Patch attached.

mcengland’s picture

--Ignore... found my error--

seutje’s picture

things like this can be easily traced back to it's origin by overriding the window.alert function to something else, console.trace for instance (requires firebug or a console.trace compatible browser)

this isn't the prettiest, but it's an easy way to inject it before everything else from within a theme's template.php:

function mytheme_preprocess_page(&$vars) {
  $vars['scripts'] = '<script type="text/javascript">window.alert = function(msg) { if (console) { console.trace(msg); } };</script>' . $vars['scripts'];
}
kbk’s picture

Component: Miscellaneous » Code
Status: Needs review » Reviewed & tested by the community

#4 Works for me. Can this be committed?

garbo’s picture

I had this error too and commenting out the line as noted at #4 worked.

But why is this alert in the code? This has been there apparently for a long time seing the postdate of this thread. Obviously the developers think it needs to be there but why?

bdragon’s picture

Status: Reviewed & tested by the community » Fixed

Actually, the problem is not that I think it needs to be there, it's that I'm doing so poorly at remembering to maintain gmap_addons that it really *has* accidentally been left in for two years.

Fixed, thanks, and sorry for the ridiculous wait.
http://drupal.org/cvs?commit=488992
http://drupal.org/cvs?commit=488994

garbo’s picture

hi bdragon,

Thanks for your reply to this! I'm glad this issue is sorted out now. And thanks for the nice software!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.