Skip Navigation

[Resuelto] Setting up a Search page with map and grid of listings

Este hilo está resuelto. Aquí tiene una descripción del problema y la solución.

Problem:

My problem is how do I setup the markers to display on the top map, currently I am not getting any markers displaying.

Solution:

It is a compatibility problem, see the solution provided by client:
https://toolset.com/forums/topic/setting-up-a-search-page-with-map-and-grid-of-listings/#post-860375

Relevant Documentation:

This support ticket is created hace 6 años, 6 meses. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Hoy no hay técnicos de soporte disponibles en el foro Juego de herramientas. Siéntase libre de enviar sus tiques y les daremos trámite tan pronto como estemos disponibles en línea. Gracias por su comprensión.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

Este tema contiene 2 respuestas, tiene 2 mensajes.

Última actualización por Line49 Design hace 6 años, 6 meses.

Asistido por: Luo Yang.

Autor
Mensajes
#849985

Tell us what you are trying to do? I want to setup a page that has a Google map at top showing the markers for the custom posts that are being displayed in the search results, followed by the search filters and then the Search results which will be a grid of custom posts.

Is there any documentation that you are following? I have started with this page: enlace oculto. I want to add the map above the Refine your search section and will change the layout under Search Results from a list to a grid.

Is there a similar example that we can see?

What is the link to your site? enlace oculto

My problem is how do I setup the markers to display on the top map, currently I am not getting any markers displaying. I can figure out how to change the lists of posts into a grid. I just don't know how to get the map above the filters and have the search results below the filters and the markers show on the map.

Here is my view code:
[wpv-layout-start]
[wpv-items-found]
[wpv-map-render map_id="map-10" map_height="400px" spiderfy="on" fitbounds='off' single_zoom='13' general_zoom='11' scrollwheel='off' marker_icon="//www.2018.vancouvernewcondos.com/wp-content/uploads/2018/05/office-building.png"][/wpv-map-render]
<h2>[wpml-string context="wpv-views"]Search Results[/wpml-string]</h2>
<!-- wpv-loop-start -->
<wpv-loop><div class="row">
<div class="col-sm-12"> [wpv-post-body view_template="Building Search"]</div>
</div>
</wpv-loop>
<!-- wpv-loop-end -->
[/wpv-items-found]
[wpv-no-items-found]
<h2>[wpml-string context="wpv-views"]No items found[/wpml-string]</h2>
<p>[wpml-string context="wpv-views"]Please try another search.[/wpml-string]</p>
[/wpv-no-items-found]
[wpv-layout-end]

and here is my Content template:
<div class="row">
<div class="col-xs-12 col-sm-3 thumbBlock">
[wpv-if image="_thumbnail_id" evaluate="!empty($image)"][wpv-post-featured-image size="category-thumb"][/wpv-if]
[wpv-if image="_thumbnail_id" evaluate="empty($image)"][/wpv-if]
</div>
<div class="col-xs-12 col-sm-9 vertical-layout">
<h2>[wpv-post-link]</h2>
<h3>[types field="address" output="raw"][/types]</h3>
[vnc2015excerpt]
</div>
[wpv-conditional if="( $(wpcf-map-address) ne '' )"]
[wpv-map-marker map_id='map-10' marker_id='marker-[wpv-post-id]' marker_title='[wpv-post-title output='sanitize']' marker_field='wpcf-map-address']
[wpv-post-body view_template="markercontent"]
[/wpv-map-marker]
[/wpv-conditional]
</div>

Thank you.

#852315

Hello,

I have checked the HTML source code of your website:
view-source:enlace oculto

There isn't HTML codes for [wpv-map-render map_id="map-10" ...]

It is abnormal, please check these:
1) you are using the latest version of Toolset plugins, you can download them here:
https://toolset.com/account/downloads/

2) deactivate other plugins and switch to wordpress default theme, and test again

3) If the problem still persists, please provide a database dump file (ZIP file) of your website in below private detail box, also point out the problem page URL, I need to test and debug it in my localhost, thanks

#860375

Hi,

It turns out that it was this parameter fitbounds='off' which was causing the issue with the map.