# Search Button (user location)

**URL:** <https://forum.bubble.io/t/search-button-user-location/319>\
**Category:** Need help\
**Created:** [October 8, 2015, 9:59am UTC](https://forum.bubble.io/t/search-button-user-location/319 "2015-10-08T09:59:10Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ItsJustBusiness](https://avatars.discourse-cdn.com/v4/letter/i/2acd7d/32.png) [@ItsJustBusiness](https://forum.bubble.io/u/ItsJustBusiness)\
**Post date:** [October 8, 2015, 9:59am UTC](https://forum.bubble.io/t/search-button-user-location/319/1 "2015-10-08T09:59:10Z")

</div>

HI guys,

I’m very new to the bubble platform and need some help understanding  
how i could create a button that find the users location that clicked the button and then search  
that postcode, then to find a shop within 5km from them. and show the result on a new page

---

<div class="post-metadata">

**Author:** ![emmanuel](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/emmanuel/32/27657_2.png) [@emmanuel](https://forum.bubble.io/u/emmanuel)\
**Post date:** [October 9, 2015, 3:31pm UTC](https://forum.bubble.io/t/search-button-user-location/319/2 "2015-10-09T15:31:11Z")

</div>

The way you’d do it is, if you were to do this on the same page (which is simpler), You’d have a repeating group that can display shops and have a workflow that does

When the button is clicked, display list in repeating group, and the data source of that action being “Do a search for shops with the constraint address is within 5km of current position” You’ll find current position in the dropdown.

No need to worry about zip code here.

---

<div class="post-metadata">

**Author:** ![cflux](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/cflux/32/485_2.png) [@cflux](https://forum.bubble.io/u/cflux)\
**Post date:** [November 24, 2015, 5:51am UTC](https://forum.bubble.io/t/search-button-user-location/319/4 "2015-11-24T05:51:49Z")

</div>

So i’ve found that its easier to create the data/ info first and then create the search functionality to go with it.

Start off making a data base for the users where they can store their location, then create the search functionality.

create search button–\> then create the repeating group as youve done, in the properties box, make the content type = geographic address

make the data source = repeating group results’ list of geographic addresses

that should be it. I think there’s a tutorial on it too you could check out.

Good Luck!
