Hi all,

1. Looking for someone to get location view proximity radius search working for city and postcode for Australia.

2. Also would like the city field to have autocomplete.

Willing to pay $50 AUD for it. Maybe some other people are willing to contribute to this $$$.

This can be contributed back to the drupal location project.

It seems lat/lon is currently working.

see.
http://drupal.org/node/321114

Or you can tell me how much it's going to cost.

cheers

Comments

juicytoo’s picture

The query should be something like this

>>>>>
$query = "SELECT i.itemid, i.title, lng.data_txt as lng, lat.data_txt as lat, ";
// Haversine formula
$query .= "( %s * acos( cos( radians(%s) ) * cos( radians( lat.data_txt) ) * cos( radians( lng.data_txt) - radians(%s) ) + sin( radians(%s) ) * sin( radians( lat.data_txt) ) ) ) as distance ";
$query .= "FROM db_item as i, db_fields_data as lat, db_fields_data as lng ";
$query .= "WHERE lng.itemid=i.itemid and lat.itemid=i.itemid and ";
// Change these numbers to your fieldid's
// Fieldid 13 is the longitude field
// Fieldid 12 is the latitude field
$query .= "lng.fieldid=16 and lat.fieldid=15 ";

if ($radius!="")
{
// if theres a radius, then limit the results
$query .= "HAVING distance <= " . $radius . " ";
}
$query .= "ORDER BY distance ";
$query .= "LIMIT 20 ";

>>>>>>

rc2020’s picture

Note, I have offered a $100 bounty on this thread (similar issue) http://drupal.org/node/357295

ankur’s picture

Status: Active » Closed (won't fix)

I believe this was added in another ticket last year.

drupalina’s picture

I'd offer an additional $50 USD bountry for 7x.
1) location field in proximity search must have an autocomplete
2) end-users can currently enter either City or Postcode, but (optionally) it would be nice if they could also enter the areas within the City, Province names etc.

Dom.’s picture

Issue summary: View changes

Hi !
I have made a patch that sound like what you would need:
#2696207: Add an address autocomplete for View proximity filter.

If the bounty is still available I would be happy with :p !!