GD > Near Me Button
All Widgets come as Widgets, Shortcodes or Blocks. Learn more about our Super Duper Widgets.
The Near Me Button displays a button that when clicked will get the user's geolocation and redirect them to your location page where listings will be sorted by distance to the user's position.
Near Me Button requires HTTPS support for full functionality otherwise a user must set their location on a map manually.
- GPS Support (Mobile Devices) - The button can use the phone's GPS settings to fetch user location.
- HTML5 Geolocation Support - Users are asked to share their location via the browser (HTTPS required), instead of IP-based geolocation which is often less reliable.
- Fallback Map Pin Support - If HTML5 geolocation is denied, users are presented with a map wherein they can drag a pin to the location they wish to search. This map automatically centers on the geolocation of the IP request -- as a result, it is never far-off from the user’s actual location.
- Title - The title for the widget.
- Button Title - Title of the Near Me button.
- Button CSS Class (A) - CSS class for the Near Me button.
Default output, with browser permissions' request after clicking the button:
If geolocation is denied or blocked by the browser or the site is not served over HTTPS a map will show in a popup for the user to set their location manually. This map will use the user's IP address to center the map initially.