Skip Navigation

[Resolved] Javascript error in frontend for ACF form

This support ticket is created 2 years, 4 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.

Our next available supporter will start replying to tickets in about 0.04 hours from now. Thank you for your understanding.

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)

This topic contains 7 replies, has 2 voices.

Last updated by Shane 2 years, 4 months ago.

Assisted by: Shane.

Author
Posts
#2417639
Bild_2022-07-14_165236494.png
Bild_2022-07-14_165019062.png

I'm building a frontend form using ACF Pro and ACF forms.

-> But this is not working as Toolset Views is throwing some errors...

#2417801

Shane
Supporter

Languages: English (English )

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

Hi Adrian,

Thank you for getting in touch.

Would you mind providing me with a copy of the site so that I can perform some tests here locally ?

I've enabled the private fields for your next response. Please follow the instructions in the link below to provide me with the site copy.
https://toolset.com/faq/provide-supporters-copy-site/

Thanks,
Shane

#2418261

Shane
Supporter

Languages: English (English )

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

Hi Adrian,

18gb that is quite large. Might be better if I logged into the site so that I can see how things are setup and perhaps try to replicate this issue locally.

I've enabled the private fields once more.

Thanks,
Shane

#2421715

Shane
Supporter

Languages: English (English )

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

Hi Adrian,

Thank you for the login details.

I'm trying to replicate the issue at the link below but i'm unable to.
hidden link

It would appear that the issue is not simply a conflict between Toolset and ACF only but there is perhaps something else at play here.

Can you see if you're able to replicate it at the test site below.
hidden link

Thanks,
Shane

#2421725

Hello Shane,

Thanks to your system I was able to identify "the problem"

I'm dequeuing some toolset scripts, in this case, when removing toolset-codemirror-script the error ocures...

See:
hidden link

#2421825

Shane
Supporter

Languages: English (English )

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

Hi Adrian,

In this case it is not a case of the plugins having compatibility issue. It's a because the codemirror script is being removed from the page.

So this is the cause of the error which is causing Views to fail adding the conditional button to your frontend form. Not much we can do about this given the cause of the issue is coming from a script.

Thanks,
Shane

#2422175

Hello Shane,

But there is a major improvement with Toolset possible: don't load unnecessary editor scripts, when there is no editor…

If Toolset would only load scripts for the editor, when an editor is shown, then this wouldn't happen at all 😉

#2422491

Shane
Supporter

Languages: English (English )

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

Hi Adrian,

Actually the script is needed to add some of the Toolset buttons to the WYSIWYG editors.

Now if you look at the issue at hand the problem that unhooking this script is causing is making the conditional buttons on the WYSIWYG field to have issues loading, which is the root cause of the error that you're experiencing.

My best advice here is to make an improvement suggestion by filling out the form at the link below.
https://toolset.com/home/contact-us/suggest-a-new-feature-for-toolset/

Thanks,
Shane