I’ve got Cool Location working fine, but I’d like to know what I need to change to remove the “map,” “hyb,” and “sat” buttons from the top of the Yahoo! map?
I want it to default to “map” and nothing else as an option.
Go into pi.coollocation.php and remove this line (should be about 287):
coollocation_map.addControl(new GMapTypeControl());
…and you’re done!
Here’s the scoop on the rest of the controls you can show/hide/tweak for Google Maps.
Hope that helps.
Oh - and if nothing is specified for type of map, it will simply default to the standard “Map” view. My preference, however, is for the new “Terrain” view that Google has.
If you want this map view, just replace that line 287 with this:
coollocation_map.setMapType(G_PHYSICAL_MAP);
and you’ll have the “Terrain” map.
Or, if you want ALL of the buttons, leave line 287 where it is, and add this line below it:
coollocation_map.addMapType(G_PHYSICAL_MAP);
Enjoy!
Not sure how many use this, but has anyone seen a problem whereby the map in the CP isn’t centered? On mine, the center point auto-fixes to the top left of the preview box. So when you double click to center the map, it goes weird and shifts the center to top left.
Other than that, it works like a charm.
Not sure how many use this, but has anyone seen a problem whereby the map in the CP isn’t centered? On mine, the center point auto-fixes to the top left of the preview box. So when you double click to center the map, it goes weird and shifts the center to top left. Other than that, it works like a charm.
Andy,
Same problem here. I’m using it on my golf site. Page where I’m using it: http://www.kentuckygolfing.com/courses/details/kearney-hill-golf-links
I contacted the developer a while ago about the problem and if I remember correctly they said they couldn’t duplicate the problem, but I’ve got around 300 entries in my database of which have a map tied to them and all 300 do it, so who knows.
I can’t help with the question at hand as I have about zero experience developing extensions, but maybe you’ve not see this? http://experienceinternet.co.uk/resources/details/sl-google-map/
Might be a better option for you since the folks that developed CoolLocation are not supporting it anymore.
Small followup:
After just over an hour I have completely removed CoolLocation, installed FieldFrame and the SLGoogleMap fieldtype, modified my settings, updated my weblogs and updated a small pile of custom code I use to display multiple locations on a google map based off of a dynamic xml file.
This is the first time I have used FieldFrame and it is now in more places than I can count on my current project.
Wicked extension, how did I do without it!
Small followup: After just over an hour I have completely removed CoolLocation, installed FieldFrame and the SLGoogleMap fieldtype, modified my settings, updated my weblogs and updated a small pile of custom code I use to display multiple locations on a google map based off of a dynamic xml file. This is the first time I have used FieldFrame and it is now in more places than I can count on my current project. Wicked extension, how did I do without it!
I feel the same way. Once I installed FieldFrame I fell in love with it. It’s now on majority of my sites. Can do a lot of things with it.
Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.