Skip Navigation

[Resolved] Adding a map with markers to a page that displays a view

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.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10: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/Kolkata (GMT+05:30)

This topic contains 8 replies, has 1 voice.

Last updated by Minesh 1 week, 3 days ago.

Assisted by: Minesh.

Author
Posts
#2811638
Schermafbeelding 2025-06-08 133958.jpg

I have a list showing on the following page hidden link. I would like it to show a map on top as like to list does that I created as a view for this function hidden link

The map is not added automatically so i tried a couple of code combinations but those do not give me the result I am looking for.

First I added [wpv-view name="gastouders-almere"] for the list

Then I added [wpv-map-render map_id="map-8"][/wpv-map-render] (the map is showing but is empty

After that I added [wpv-map-marker map_id='map-9' marker_id='marker-10' marker_field='wpcf-adres'][/wpv-map-marker] but the markers to not show on the map.

As I am using Divi it is showing as the attachement.

Can you help me out as I do not get what to so to get it right.

Thanks

#2811703

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

Based on the screenshot you shared.

I see that the map_id is set as "map-8": [wpv-map-render map_id="map-8"][/wpv-map-render]

And with the map marker - you are using map_id as 'map-9':
- [wpv-map-marker map_id='map-9' marker_id='marker-10' marker_field='wpcf-adres'][/wpv-map-marker]

The map_id should be same for map render and map marker shortcode.

So, what if you try to change the map marker shortcode attribute map_id as given under:

 [wpv-map-marker map_id='map-8' marker_id='marker-[wpv-post-id]' marker_field='wpcf-adres'][/wpv-map-marker]

Please check the following Doc:
- https://toolset.com/documentation/legacy-features/maps-plugin/
- https://toolset.com/documentation/legacy-features/maps-plugin/displaying-markers-on-maps/

Also, please make sure that you have registered the map API key if you are using Google or Azure map.
- https://toolset.com/course-lesson/creating-a-maps-api-key/

#2812159

Thank you for your response but unfortunately this didn't do the trick.
The shortcode that is now in the page is the following
[wpv-map-render map_id="map-8"][/wpv-map-render]
[wpv-map-marker map_id='map-8' marker_id='marker-9' marker_field='wpcf-adres'][/wpv-map-marker]
[wpv-view name="gastouders-almere"]

As you can see on the page the map is showing but no markers.

Looking forward to your wisdom.

#2812355

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Can you please share problem URL and admin access details and tell me what address field you want to display on map with marker.

*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin and FTP) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.

I have set the next reply to private which means only you and I have access to it.

#2812828

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Can you please check now: hidden link

you were mixing the block view and classic view.

To make this work, I've added a content template that will hold the Map block as well as view block.
=> hidden link

And then I've added the above content template to your Divi builder template using the shortcode:

[wpv-post-body view_template="ct-as-container-for-map"]

=> hidden link

Can you please confirm it works as expected.

#2812869

That's great thanks a lot, I didn't think that was the solution. Can you give me a little guide of how to copy this template for other regions? I have to make 10 of these.

Thanks a lot.

#2812897

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

What you mean?

Do you mean you want to display the same map and view on other page/posts? if yes:

You can just simply add the content template shortcode I shared:

[wpv-post-body view_template="ct-as-container-for-map"]

That will display the map and view.

#2813086

No sorry, not the same map. A different map with other results but one that has the same look and feel.

#2813103

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Well - you should create a content template that should work as a container and add new map block and view block to that and add that newly created content template that has map and view block to your elementor's template using the [wpv-post-body view_template="your-content-template-slug"] shortcode.