Skip Navigation

[Resolved] I'm getting a Google Maps error, presumably from the Toolset shortcode I'm using

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.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

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/Karachi (GMT+05:00)

This topic contains 3 replies, has 2 voices.

Last updated by Elsie 1 year, 4 months ago.

Assisted by: Waqar.

Author
Posts
#2611339

I am trying to:

Get a map to work using a business post type that has addresses

I have this in the loop editor:
[wpv-map-render map_id="map-1" map_width="100%" map_height="500px"]

and this in the loop template:
[wpv-map-marker map_id="map-1" marker_id="marker-[wpv-post-id]" marker_title="[wpv-post-title]" marker_field="[types field='address-business' output='raw'][/types]"]This is the content of the marker popup.[/wpv-map-marker]

Link to a page where the issue can be seen:

hidden link

I expected to see:

A map with hundreds of businesses on it

Instead, I got:

Just a blank map

#2611341

Sorry, the error I'm getting is this:
google.maps.event.addDomListener() is deprecated, use the standard
addEventListener() method instead

#2611461

Hi,

Thank you for contacting us and I'd be happy to assist.

The depreciation notice that you see in the browser's console is safe to ignore.

In the 'wpv-map-marker' shortcode, you just need to include the address field's slug with the 'wpcf-' prefix, for the 'marker_field' attribute:
( ref: https://toolset.com/documentation/programmer-reference/maps/maps-shortcodes/#wpv-map-marker )


[wpv-map-marker map_id="map-1" marker_id="marker-[wpv-post-id]" marker_title="[wpv-post-title]" marker_field="wpcf-address-business"]This is the content of the marker popup.[/wpv-map-marker]

This should fix it.

regards,
Waqar

#2611633

My issue is resolved now. Thank you so much!

This ticket is now closed. If you're a Toolset client and need related help, please open a new support ticket.