Skip Navigation

[Résolu] Javascript error when trying to upload an image

Ce fil est résolu. Voici une description du problème et la solution proposée.

Problem:

I am trying to: upload an image using the image field in a Toolset Form

Instead, I got some JS errors.

Solution:

It seems to be a compatibility issue, please try these:

https://toolset.com/forums/topic/javascript-error-when-trying-to-upload-an-image/#post-1854389

Relevant Documentation:

This support ticket is created Il y a 4 années. 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.

Aucun de nos assistants n'est disponible aujourd'hui sur le forum Jeu d'outils. Veuillez créer un ticket, et nous nous le traiterons dès notre prochaine connexion. Merci de votre compréhension.

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)

Ce sujet contient 2 réponses, a 2 voix.

Dernière mise à jour par Darryl Il y a 4 années.

Assisté par: Luo Yang.

Auteur
Publications
#1854263

I am trying to: upload an image using the image field in a Toolset Form

Instead, I got:

toolset-media-field.prototype.js:289 Uncaught TypeError: _.contains is not a function
at Toolset.CRED.MediaField.Toolset.Common.MediaField.manageInputSelectorClick (toolset-media-field.prototype.js:289)
at HTMLInputElement.<anonymous> (toolset-media-field.prototype.js:84)
at HTMLDocument.dispatch (jquery.js:3)
at HTMLDocument.r.handle (jquery.js:3)
Toolset.Common.MediaField.manageInputSelectorClick @ toolset-media-field.prototype.js:289
(anonymous) @ toolset-media-field.prototype.js:84
dispatch @ jquery.js:3
r.handle @ jquery.js:3

#1854389

Hello,

It seems to be a compatibility issue, please try these:
1) deactivate all other plugins, and switch to wordpress default theme 2020, deactivate all custom PHP/JS code snippets, and test again

2) Also check if there is any PHP/JS error in your website:
https://toolset.com/documentation/programmer-reference/debugging-sites-built-with-toolset/

3) If the problem still persists, please provide database dump file(ZIP file) of your website, you can put the package files in your own google drive disk, share the link only, also point out the problem page URL and form URL, I need to test and debug it in my localhost, thanks
https://toolset.com/faq/provide-supporters-copy-site/

#1859503

My issue is resolved now. Thank you!