Need Radius Search Implementation on Bubble.is
New here? Learn about Bountify and follow @bountify to get notified of new bounties! x

This is for development on bubble.is platform. I am trying to build an app which will allow me to enter Address, City, Zip....and hit search..and in next page show the list of locations which are within x mile radius of the address. Please send me a running example of this, so i can replicate for my project.

I remember implementing a similar functionality where the user has to pick a point or enter an address on google maps and then enter the radius, it then searches all places in the database which are within the radius of selected address. Let me know is this what u want.Thank you
Codeword 4 months ago
I have a database of locations with addresses...I want the user to be able to enter the address or zip , select radius (5 miles, 10 miles, 20 miles etc) and click Search..and on next page it must display the locations found. All locations are stored in database as street address, city, state, zip . I think we have to use a repeating group to display and somehow filter it to those addresses that match the radius criteria...we may need to geocode the addresses...i assume..to make this happen...not sure. Look forward to your solution.
aasker 4 months ago
Then I think I have the perfect solution for you, it the same as mine. I am sending you the code soon.Thank you
Codeword 4 months ago
awesome. thanks
aasker 4 months ago
awarded to CyteBode

Crowdsource coding tasks.

1 Solution

Winning solution

This is my first time using bubble.is, and I don't know how to share the app itself, but here's my working example: https://bountifyradiussearch.bubbleapps.io/version-test?debug_mode=true

The database contains a few addresses in New York.

Can you send me the screenshots of how you set it up...the screenshots of the settings in bubble etc
aasker 4 months ago
I can do this over Slack if you want.
CyteBode 4 months ago
i dont have slack installed..if you can screenshot..or use RecordIt (its a mac app) that allows you to share your screen recording...
aasker 4 months ago
All right, I'll compile a series of screenshots in an Imgur album then.
CyteBode 4 months ago
There you go: https://imgur.com/a/p9dulu8
CyteBode 4 months ago
In search for locations...you have Address is within Current Page RadiusLocations Distance etc... the word 'is within' is not an option..i have only 'is in' or isnt in, contains, doesnt contain...
aasker 4 months ago
I have "is within", "is empty" and "isn't empty". Is the type for Address set as a "geographic address" in both the Location and RadiusLocation fields? (As shown in the first screenshot.)
CyteBode 4 months ago
Yes. i set as geographic address. let me share my screenshot
aasker 4 months ago
Yes. i set as geographic address. let me share my screenshot http://tinypic.com/view.php?pic=14ils8o&s=9#.Wz-Uk9hKg8Y
aasker 4 months ago
Can you show me the "Fields for type warehouse" in the "Data" tab?
CyteBode 4 months ago
http://tinypic.com/view.php?pic=2akb446&s=9#.Wz-XO9hKg8Y http://tinypic.com/view.php?pic=289x939&s=9#.Wz-XdNhKg8Y http://tinypic.com/view.php?pic=2i6fau1&s=9#.Wz-Xm9hKg8Y http://tinypic.com/view.php?pic=2i6fau1&s=9#.Wz-XuthKg8Y sorry..got a lot of fields..i did not list all but covered the important ones here..the other are just delivery time fields irrespective of the data structure..the option is within..does not seem to be available in bubble...atleast for me here
aasker 4 months ago
Yeah you see, Street Address is of type "text" instead of "geographic address". That's the problem.
CyteBode 4 months ago
what should i put for city, state and zipcode?
aasker 4 months ago
bubble.is treats a geographic address as a single field only, which it can parse automatically from a text string containing sufficient information (thanks to Google Maps). For example "Central Park" is enough for it to parse it as "Central Park, New York, NY, USA". If you really need to keep separate fields for another purpose, you will need to create a new field that has the proper geographic address type and mirrors the info in the other fields.
CyteBode 4 months ago
since i am capturing address in seperate fields...street address, city, state, zip..is it sufficient for me to use just street address..or do you suggest i also contatenate city, state, zip...?
aasker 4 months ago
I think you better concatenate everything in a single field. It needs to be precise enough that Google Maps can recognize it as the proper location, but not too redundant either as to confuse it.
CyteBode 4 months ago
By the way, would you mind awarding me the bounty? I believe I already accomplished what you asked for by providing you a working example. Helping you integrate the solution to your own app is extra work, and I'm not forcing you to tip me for it, but as far as the bounty goes, the work's done. Wouldn't you agree?
CyteBode 4 months ago
what is the type of field i must have for city, state and zip?. I currently have them as text fields
aasker 4 months ago
Thanks for awarding me the bounty. As I said already, you only need a single field of type geographic address in order for the radius query to work. As for the other fields, you're free to keep them as text fields if you still need them.
CyteBode 4 months ago