Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

All other Modules /

Discuss all other Modules here.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Locations Module/Google Maps Issue


Reply


3 Posts   380 Views

Avatar
ambient

Community Member, 123 Posts

13 August 2013 at 4:52am

Hi All,

I've been using the Locations module on a clients website with great success but recently they surpassed 26(a-z) locations causing
the map to crash (disappear).

I've driven myself crazy trying to figure out a way to use numbers instead of letters but have not been able to figure it out.

Does anyone have any idea of how this problem of being limited to 26 locations could be fixed?

Any help would be very much appreciated.

Avatar
Nobrainer Web

Community Member, 137 Posts

13 August 2013 at 7:11am

I Think you should look at the function ón Line 64 of https://github.com/webair/thinc.silverstripe.locations/blob/master/code/PoiLocationPage.php

Changing
$poi->Label = chr(65 + $i);
To

$poi->Label = $i;
Should give you a number as label.

Note that you may have to change Line 23 of
https://github.com/webair/thinc.silverstripe.locations/blob/master/templates/Layout/PoiLocationPage.ss
As that file might not exist.

Hope it helps

Avatar
ambient

Community Member, 123 Posts

14 August 2013 at 5:01am

Dude you are a legend!!! Thank you so much!!

I thought it might have had something to do with that line but I couldn't figure out what the chr(65+$i) did or meant.

My programming skills aren't the greatest (obviously) so thanks again :D