Hi

I created a new location.za.inc file for South Africa.

I installed the zipcode database on my localhost and whan i enter the City, Province, and Postal code it geocodes the node to the correct lat/long.

I also managed to get the Mapquest link to work.

But when i install it on my web server it does not work, only the link from mapquest.

I did run some updates randomly on my local machine, now I don't know if that is what activated the zipcode geocoding.

Do you have to run an update when you install a new country. I installed the zipcodes using phpadmin locally.

Here is the location.za.inc file if you would like to take a look.
It has 1 new feature for South Africa.

CommentFileSizeAuthor
location.za_.txt5.01 KBvlooivlerke

Comments

vlooivlerke’s picture

Ok I figured this out. This must be the worse Hack ever.

First i upload a location.za.inc file containing the script to geocode via geocode.com. In the location settings page (admin/settings/location/geocoding) i select geocode option for South Africa (does not exists for SA, I created a fake one). Then i save it. Then i remove the script from the location.za.inc file and resubmit it. When i visit my geocoding options (admin/settings/location/geocoding) it states there is no option to select for South Africa, but it states, geocode options already configured.

Now my postal codes work, by geocoding postal code level.

Where am i going wrong?

Cant we have a option to geocode via postal code level. (Radio Button)
Setting at: admin/settings/location/geocoding

Thanks Paul

vlooivlerke’s picture

OK I figured it out.

To get South Africa postal codes to work, with the supplied location.za.inc file I changed the varible called

location_geocode_za - s:4:"none";

to

location_geocode_za - s:11:"geocoder|za";

Now it works.
This is a terrible hack.

nravens’s picture

I didn't get this to work. I added the location.za.inc file to locations/supported folder is that correct?

what else do i need to do?

yesct’s picture

Title: postal codes work offline but not online » postal codes work offline but not online - faking geo-coding (South Aftrica, location.xx.inc and location.za.inc)
Issue tags: +location geo-coding

adding location.xx.inc so if someone has a similar problem, but not specifically for south africa, they might find this issue. Also tagging with geo-coding.

UNarmed’s picture

Any luck on this? I cant seem to get South africa to geocode ... =/

legolasbo’s picture

Issue summary: View changes
Status: Active » Closed (outdated)

Closing old D6 issues as D6 is end of life