Skip Navigation

[Resuelto] Uncaught TypeError: viewUniqueId[dot]split is not a function

This support ticket is created hace 4 años, 4 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.

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/Hong_Kong (GMT+08:00)

Etiquetado: ,

This topic contains 10 respuestas, has 2 mensajes.

Last updated by Luo Yang hace 4 años, 3 meses.

Assisted by: Luo Yang.

Autor
Mensajes
#1410003

The select menu on this page worked fine before I updated Toolset plugins recently:
hidden link

If you view that page with the console open and select a state from the select menu, this appears in the browser console (and breaks the subsequent function of that menu):

Uncaught TypeError: viewUniqueId.split is not a function
at WPViews.ViewAddonMaps.self.cleanupMarkersFromMapBlock (wpv_addon_maps.js?ver=2.0:1311)
at HTMLDocument.<anonymous> (wpv_addon_maps.js?ver=2.0:1289)
at HTMLDocument.dispatch (jquery.js?ver=1.12.4-wp:3)
at HTMLDocument.r.handle (jquery.js?ver=1.12.4-wp:3)
at Object.trigger (jquery.js?ver=1.12.4-wp:3)
at Object.a.event.trigger (jquery-migrate.min.js?ver=1.4.1:2)
at HTMLDocument.<anonymous> (jquery.js?ver=1.12.4-wp:3)
at Function.each (jquery.js?ver=1.12.4-wp:2)
at a.fn.init.each (jquery.js?ver=1.12.4-wp:2)
at a.fn.init.trigger (jquery.js?ver=1.12.4-wp:3)

I have confirmed that on my local version of the site this is not happening, so it appears to be a bug introduced in either the Maps or Views plugins, AFAIK.

The live site is running Types 3.3.8, Maps 2.0 and Views 3.0.

My local site is running Types 3.3.6, Maps 1.8.4, and Views 2.9.3.

#1411233

Hello,

The problem you mentioned above is abnormal, please try these:

1) In case it is a compatibility problem, please deactivate all other plugins, and switch to wordpress default theme 2020, deactivate all other custom PHP/JS codes, and test again

2) If the problem still persists, please provide database dump file(ZIP file) of your website, I need to test and debug it in my localhost, thanks
https://toolset.com/faq/provide-supporters-copy-site/

#1411919

I tried to upload the duplicator zip file of the entire site and it didn't work ("file size error"). How do I proceed?

#1412577

For sharing purposes, you could use services like DropBox and Google Drive among others, for example you can put the duplicator package in your own google drive disk, and share the link in below private message box

#1414191

Thanks for the details, I can download the files, will update here if there is anything found

#1414389
map5.JPG

I can see the problem with the duplicator package you provided, so I have tried to duplicate the same problem in a fresh WordPress installation, but it works fine.

Then I tried it in the duplicator package, with below steps:
1) Create a post view, query "Locations" posts, with same filters and custom search form(without the custom HTML codes as your post view "Locations with Map 4")
2) Create new page, put the map shortcode and view shortcode insider content, it works file.

See screenshot: map5.JPG

So it might be compatibility issue with your custom HTML codes, I suggest you try to re-setup the post view and page from fresh start, and test again.

#1416699
Screen Shot 2019-12-19 at 9.40.27 AM.png

Hey Luo,

I created a new locations view and plain page like you did, and inserted the map and new view blocks. The 'states' dropdown is working in the view... However, the map isn't updating as it is in your screenshot. There are no JS errors in the browser console. I also tried switching to the TwentyTwenty theme, but the map still didn't update.
What might I be missing?

#1417337

There isn't marker block yet, I suggest you try the map marker shortcode directly, for example:

[wpv-map-marker map_id='map-0' marker_id='marker-[wpv-post-id]' marker_field='wpcf-address'][/wpv-map-marker]

Please replace "map-0" with your map ID

#1418725

Thanks Luo, I finally got it working after recreating the View and using the shortcode instead of the Map block (not Marker block), as you suggested. I also needed to use "Let me choose individual settings" for the Custom Search Settings in the View and inserted my javascript function to be call after ajax refresh. I didn't know that feature was there. 🙂

#1418727

My issue is resolved now. Thank you!

#1458873

Hello,

This issue is fixed in Toolset Maps plugin version 2.0.1, you can download it here:
https://toolset.com/account/downloads/

Please test it and feedback if the problem is fixed. thanks

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