• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Developing a complex search...

[eluser]Wonder Woman[/eluser]

I'm looking to develop a complex search which takes a location and/or postcode which returns the lat/long coordinates of this place and then searches for places which are located near within a specified radius parameter which will be selected. Does this make sense? Similar to how http://www.rightmove.co.uk do their property search?

I've not done anything this complex before and I have managed to download a file from http://www.easypeasy.com which has all of the postcodes in for the UK and it also has the lat/long coordinates of these postcodes as well. I figured this would be useful.

If you could help me in any way I would be most grateful.


The simplest way would be to use an existing API. Check out Yahoo Placefinder: http://developer.yahoo.com/geo/placefinder/

This is done with the haversine formula, which is an implementation of the great circle distance formula. It's relatively easy to implement, it can be done in a single MySQL statement (give lat and long, get zip codes within X distance). Google happily gives you several examples of this.

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.