Skip Navigation

[Resolved] Error jQuery Deferred exception: Cannot read property 'indexOf' of undefined"

This support ticket is created 4 years, 7 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
- 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 -
- 13:00 – 18:00 13:00 – 18:00 13:00 – 18:00 14:00 – 18:00 13:00 – 18:00 -

Supporter timezone: America/Jamaica (GMT-05:00)

Tagged: 

This topic contains 9 replies, has 3 voices.

Last updated by foguinho 4 years, 7 months ago.

Assisted by: Shane.

Author
Posts
#1339845

I migrated my site and one of my page seems to be having issue, the error I am getting is:

jquery.min.js:2 Uncaught TypeError: Cannot read property 'indexOf' of undefined
    at k.fn.init.k.fn.load (jquery.min.js:2)
    at HTMLImageElement.<anonymous> (wpv-pagination-embedded.js?ver=2.9.1:3384)
    at Function.each (jquery.min.js:2)
    at k.fn.init.each (jquery.min.js:2)
    at HTMLDivElement.<anonymous> (wpv-pagination-embedded.js?ver=2.9.1:3382)
    at Function.each (jquery.min.js:2)
    at k.fn.init.each (jquery.min.js:2)
    at WPViews.ViewPagination.self.init_preload_images (wpv-pagination-embedded.js?ver=2.9.1:3370)
    at WPViews.ViewPagination.self.init (wpv-pagination-embedded.js?ver=2.9.1:3432)
    at new WPViews.ViewPagination (wpv-pagination-embedded.js?ver=2.9.1:3437)

The view works fine on my orignal site.
The page with issue is : hidden link

I can see, search filters being rendered, but my search result view, is not being rendered. I seem to have no clue how to approach this error. I did find, a question(https://toolset.com/forums/topic/error-uncaught-typeerror-cannot-read-property-indexof-of-undefined/) but it didn't help me.

#1339849

Also there is this funny thing happening.
When I switch my website to mobile view and refresh the page again, I can see the content. But if I do the same on desktop it doesn't render at all.

#1339979

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Puneet,

Thank you for getting in touch.

This could quite possibly be caused by a plugin conflict and as such I would recommend that you temporarily disable all your non-toolset plugins and try again.

Also we have released an update to our plugins so you can update and let me know if the issue still remains.

Thanks,
Shane

#1340721

Hey Shane,

Sorry for the late reply.

I have updated all the toolset related plugins. I also tried deactivating non-toolset plugins, but couldn't find the reason, causing this.
This sounds very wired that the loop item shows when I change my chrome to a mobile view - reload the page to find everything working fine. Example page : hidden link

And when there is no, data it the loop it correctly says "No items Found". Example page : hidden link

#1340951

Hey Shane, any update on this issue ?

#1341291

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Puneet,

Would you mind allowing me to have admin access to the website so that i can check on this in further detail for you ?

It could also be an issue caused by the theme but I would need to have a look for you.

Thanks,
Shane

#1341293

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

private fields

#1341477

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Puneet,

Add the following to your css editor for the view. The real issue was that something is adding a visibility hidden to the view.

.js-wpv-view-layout{

visibility: hidden;

}

Once you add this it should start show up.

Thanks,
Shane

#1341701

Hey Shane,

Thanks this indeed, was the problem.

But I am literally unaware, where did that inline style came inside the div.

#1348475

I had the same problem. The code posted here solved the problem, but when I put the css on the content template, because for some reason the css put on the view was not loading. I don't know if it is happening just with me, but I thought it could help others with the same problem.

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