Hi team,
i have issue with distance filter, i already have full filter running .
what i did was just add the distance filter .
i tested with 1km radius i get the same number of listing all time, pls advice.
i follwed this guide : https://toolset.com/documentation/user-guides/display-on-google-maps/displaying-markers-on-google-maps/#filtering-markers-by-distance
wonder, do i need another separate search button just for distance ?
Hi, you do not need a separate submit button just for the distance filter. It should be integrated with all the other filters. Can you tell me more about how this is implemented?
- Is this custom search in a View or a WordPress Archive?
- Are you trying to filter based on the User's current location, or based on the distance from a specific point?
- Do you have a map implemented? If so, are there Markers shown for each location? Are they shown in the correct place?
- If you change other filters on the View, do the results change?
- Is this View visible somewhere on the site?
Hi Christian,
1. its under wordpress archieve page.
2. user current location - " use my location "
3. map with markers is active
4. link: hidden link [site is blocked for google pls dont publish url anywhere 🙂 ]
thanks.
Hi. is this line fixed ?
distance_center_url_param="toolset_maps_distance_center"
distance_radius_url_param="toolset_maps_distance_radius"
distance_unit_url_param="toolset_maps_distance_unit"
can i change it to my likings ?
eg:distance_center_url_param="mysite_maps_distance_center"
thanks
Yes, it's most likely the same issue here. The distance filter is not yet implemented in WordPress Archives. You could achieve something similar with a custom search View, placed inside the WordPress Archive Loop Output editor, outside the wpv-loop tags. Then remove everything inside the wpv-loop tags.
thanks.
ill try now and update here soon. cheers
hi christian could you guide me step by step pls. correct me too
1. create new view '> post type : i must select ? cant be auto detect ?
2. query filter : distance
3. Custom Search Settings > AJAX results update when visitors click on the search button >> meaning i need to add button now ? cant use the same button for the archieve filter ?
4. filter editor
[wpv-filter-start hide="false"]
[wpv-filter-controls]
<div class="mysite_dist_search">
[wpv-control-distance compare_field="mysite-address"
distance_center_url_param="mysite_maps_distance_center"
distance_radius_url_param="mysite_maps_distance_radius"
distance_unit_url_param="mysite_maps_distance_unit"]
</div>
[/wpv-filter-controls]
[wpv-filter-end]
5. Loop Output Editor >
[wpv-layout-start]
[wpv-items-found]
<!-- wpv-loop-start -->
<wpv-loop>
</wpv-loop>
<!-- wpv-loop-end -->
[/wpv-items-found]
[wpv-layout-end]
6 back to archieve page : add
<div class="mysite_dist_search">
[wpv-control-distance compare_field="mysite-address"
distance_center_url_param="mysite_maps_distance_center"
distance_radius_url_param="mysite_maps_distance_radius"
distance_unit_url_param="mysite_maps_distance_unit"]
</div>
after
[wpv-layout-start]
[wpv-items-found]
.
anything wrong here to highlight? thanks
1. create new view '> post type : i must select ? cant be auto detect ?
You must select the post type. The View is completely separate from the archive and it does not automatically detect what you want.
3. Custom Search Settings > AJAX results update when visitors click on the search button >> meaning i need to add button now ? cant use the same button for the archieve filter ?
You need to add the search button to this View. Remove all filters and buttons from the WordPress Archive's filter editor.
5. Loop Output Editor
In between the wpv-loop tags, add the post title, a map marker, or anything else you originally included in the WordPress Archive loop.
6 back to archieve page : add
No, don't add any filters to the archive. Delete all filters from the archive.