You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When i try to use the search on proximity I get an SQL error Column not found distance whatever i put in for the order e.g. MyFieldHandle_distance I still get Column not found ... Any idea how to fix this?
This is the code I use:
{% set query = craft.request.getParam('q') %} {% if query is defined %} {% set searchParams = { 'address': query, distance: 200 } %} {% set foundLocations = craft.entries.section('locations').map(searchParams).order('googleMapField_distance asc') %} {% else %} {% set foundLocations = locations %} {% endif %}
The text was updated successfully, but these errors were encountered:
Re-installed the plugin and re-saved the entries. now the SQL error is gone and search is working, but marker.distance is empty.
Nevermind got it working: I used location.map.markers instead of location.map.markers() ... both work except the latter returns distance, the first one does not.
Hi,
When i try to use the search on proximity I get an SQL error Column not found distance whatever i put in for the order e.g. MyFieldHandle_distance I still get Column not found ... Any idea how to fix this?
This is the code I use:
{% set query = craft.request.getParam('q') %}
{% if query is defined %}
{% set searchParams = { 'address': query, distance: 200 } %}
{% set foundLocations = craft.entries.section('locations').map(searchParams).order('googleMapField_distance asc') %}
{% else %}
{% set foundLocations = locations %}
{% endif %}
The text was updated successfully, but these errors were encountered: