$lon = //your longitude
$lat = //your latitude
$miles = //your search radius
$query = "SELECT *,
( 3959 * acos( cos( radians('$lat') ) *
cos( radians( latitude ) ) *
cos( radians( longitude ) -
radians('$lon') ) +
sin( radians('$lat') ) *
sin( radians( latitude ) ) ) )
AS distance FROM yourtable HAVING distance < '$miles' ORDER BY distance ASC LIMIT 0, 5"
Tomado de aqui: http://stackoverflow.com/a/10771017/1459272
Ejemplo:
SELECT * , ( 3959 * acos( cos( radians( - 89.555382 ) ) * cos( radians( latitude ) ) * cos( radians( longitude ) - radians( - 89.555382 ) ) + sin( radians( - 89.555382 ) ) * sin( radians( latitude ) ) ) ) AS distance
FROM fjztu_zhgooglemaps_markers
HAVING distance <10000
ORDER BY distance ASC
LIMIT 0 , 5