Skip Navigation

[Resolved] Map missing

This support ticket is created 5 years, 8 months ago. 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.

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 13 replies, has 2 voices.

Last updated by winyS 5 years, 7 months ago.

Assisted by: Minesh.

Author
Posts
#1246013

I created a maps view that fine for some time. But now the map seems to be missing. Instead of the map I see a white space. In the html I see the views code. Can you see what's wrong here?
URL: hidden link
Thanks,
Winy

#1246248

Minesh
Supporter

Languages: English (English )

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

Hello. Thank you for contacting the Toolset support.

Well - I need access details in order to check why Map is not displaying on the page which you shared.

*** 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.

#1246479

Minesh
Supporter

Languages: English (English )

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

Well - I see there is a console error on your page that belongs to map:

Uncaught ReferenceError: google is not defined
    at new WPViews.ViewAddonMaps (wpv_addon_maps.js?ver=1.7.2:13)
    at HTMLDocument.<anonymous> (wpv_addon_maps.js?ver=1.7.2:1498)
    at i (jquery.js?ver=1.12.4:2)
    at Object.fireWith [as resolveWith] (jquery.js?ver=1.12.4:2)
    at Function.ready (jquery.js?ver=1.12.4:2)
    at HTMLDocument.K (jquery.js?ver=1.12.4:2)

In addition to that, I see on your page you added two view's, does that mean we need to display two different maps that is one map to display Observers and one map to display members?
Or
you want to combine both results on a single map?

#1247685

I want to combine both results on a single map
So 2 separate views provide the marker information. The Markers are targeting the same Map id then they will be displayed on the map.
You can see how I created it in this ticket: https://toolset.com/forums/topic/one-map-with-2-post-types/

#1247725

Minesh
Supporter

Languages: English (English )

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

Ok - Do you want me to pass this ticket to Shane?

#1247729

Ok, if you want. Or maybe you can resolve it?

#1247779

Minesh
Supporter

Languages: English (English )

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

Well - as I shared the information with the following reply there is a JS error:
=> https://toolset.com/forums/topic/map-missing/#post-1246479

I again tested and I still see the JS error, is this your live site? if yes, I need a test site where I can change themes, disable/enable plugins etc..etc..

Can you confirm the current site is test site or share test site where I can do further debugging.

#1249109

I created a staging site: hidden link
You can log in with the same credencials.

#1249137

Minesh
Supporter

Languages: English (English )

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

Thank you for sharing all required information.

I checked and debug further on the staging site your shared and I found that when I deactivate the plugin "WeePie Cookie Allow" the JS error is gone and maps displaying correctly.

Please check here:
=> hidden link

#1249465

Thank you Minesh,
Great that you have found the plugin that caused the error.

However, on this page: hidden link
I now see 2 maps instead of one map that displays the 2 views.

Can you take a look at this?

#1251057

Minesh
Supporter

Languages: English (English )

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

Well - I do not know why you created two views to display Observers and members?

As you can go with only one view where you can select both post types together. Please check the following screenshot.
=> hidden link

You can checkmark both post types so you can display both post types posts with one map and one view.

#1251061

Is it then possible to show different marker icons for members and observers?

#1251105

Minesh
Supporter

Languages: English (English )

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

Yes - you can use the shortcode [wpv-post-type] to check current post's post type with [wpv-conditional] shortcode.

For example:

[wpv-conditional if="( '[wpv-post-type]' eq 'members' )"]

// display marker for members

[/wpv-conditional]

[wpv-conditional if="( '[wpv-post-type]' eq 'observers' )"]

// display marker for observers

[/wpv-conditional]

More info:
=> https://toolset.com/documentation/user-guides/conditional-html-output-in-views/checking-types-fields-and-custom-fields/

#1251777

My issue is resolved now. Thank you!