How to implement proximity search with a zip code?

I need to use the proximity search with a zip code for Australia. Following some links, such as http://www.randommouse.com/rms/about/product/FNDRY/docs/tutorial/08/how-to-add-google-maps-to-your-review-site-intro. html

I found that I need to manage postal codes with latitude and longitude if I am not mistaken. But I could not find how to implement this. Can someone suggest me how to do this with php or give some links so that I can see more about it.

Thanks in advance.

Edited by:

I edited my question:

Is it possible to use google api for this to get postal codes in a given range. I found a link for drupal. Therefore, I can use google api to get zip codes. Following link: http://svendecabooter.be/blog/implementing-location-proximity-search-for-belgium-with-drupal-and-google-maps

+3
source share
3 answers

GeoHash / (). , "" . GeoHash Ruby .

0

MySQL Geo, .  https://www.percona.com/blog/2013/10/21/using-the-new-spatial-functions-in-mysql-5-6-for-geo-enabled-applications/

, AusPost . Google Mapping, , , Google.

/lng, , http://www.computerpros.com.au/data/australian_suburbs.sql

Mysql :

+----------+----------------------+------+-----+---------+-------+
| Field    | Type                 | Null | Key | Default | Extra |
+----------+----------------------+------+-----+---------+-------+
| id       | int(10) unsigned     | NO   |     | 0       |       |
| name     | varchar(64)          | NO   |     | NULL    |       |
| postcode | varchar(4)           | NO   |     | NULL    |       |
| state    | smallint(5) unsigned | NO   |     | NULL    |       |
| lat      | float(10,6)          | NO   |     | NULL    |       |
| lng      | float(10,6)          | NO   |     | NULL    |       |
+----------+----------------------+------+-----+---------+-------+
0

Source: https://habr.com/ru/post/1724466/


All Articles