Possible Bug in Geocoder?

I'm using the latest version of the Geocoder plugin with CMSB 2.08. Everything works great except for one anomaly!

When I add Sidney, BC to the Geocoder, it display Sidney, Australia instead (lat & long are for Aus).

Any ideas?
--
northernpenguin
Northern Penguin Technologies

"Any sufficiently advanced technology
is indistinguishable from magic."
........Arthur C. Clarke

Re: [northernpenguin] Possible Bug in Geocoder?

By Dave - August 16, 2011

Hi northernpenguin,

You can set a "bias" for the region in the top of the plugin. Just replace this line:

// two-letter ccTLD, eg: us, GB, ref: http://code.google.com/apis/maps/documentation/javascript/basics.html#Region
//$GLOBALS['GEOCODER_REGION'] = 'us';

With this:
// two-letter ccTLD, eg: us, GB, ref: http://code.google.com/apis/maps/documentation/javascript/basics.html#Region
$GLOBALS['GEOCODER_REGION'] = 'CA';

Can you let me know if that makes a difference? If not we'll have to do some more digging. :)

Hope that helps!
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] Possible Bug in Geocoder?

Dave: No joy! I still get Sydney, AUS (-34.0232131, 150.8223535).

http://bc.aircadetleagueofcanada.ca/maps.php

Very weird, especially that if I do go to maps.google.com, Sidney BC is displayed correctly.

Ragi
--
northernpenguin
Northern Penguin Technologies

"Any sufficiently advanced technology
is indistinguishable from magic."
........Arthur C. Clarke

Re: [northernpenguin] Possible Bug in Geocoder?

By Dave - August 16, 2011

Ragi,

Can you email me CMS & FTP login details to dave@interactivetools.com and I'll have one of our guys debug it. Note: Email, don't post login details to the forum.

My first guess is there's a weird character or something in there that is throwing off google maps. We'll have to see, though.
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] Possible Bug in Geocoder?

Dave: I emailed you the info. BTW, I tried inputting "Sydney, NS" and it worked.

Ragi
--
northernpenguin
Northern Penguin Technologies

"Any sufficiently advanced technology
is indistinguishable from magic."
........Arthur C. Clarke

Re: [northernpenguin] Possible Bug in Geocoder?

By Dave - August 17, 2011

Hi Ragi,

I think the problem is that google can't map this address:
http://maps.google.ca/maps?q=1979+de+Havilland+Dr.,+Sidney,+BC,+V8L+5V5

You can see what the Google Maps API returns directly here:
http://maps.googleapis.com/maps/api/geocode/json?sensor=false&address=1979+de+Havilland+Dr.,+Sidney,+BC,+V8L+5V5

Is it possible there's a different address? I've gotten this one a few times:
1979 Anson Dr, North Saanich, BC V8L 5V5

Let me know what you think or if you can find an address the returns a result at maps.google.com.

Thanks!
Dave Edis - Senior Developer
interactivetools.com

Re: [northernpenguin] Possible Bug in Geocoder?

By Dave - August 17, 2011

Hi Ragi,

It could be an error with google maps. You can report errors here: http://maps.google.com/support/bin/answer.py?hl=en&answer=98014

I actually did that once before and it can take some time to get updated.

In the meantime you might want to see if you kind find an alternate address that works.

Let me know if there's anything else I can do to help.
Dave Edis - Senior Developer
interactivetools.com