Skip Navigation

[Resolved] Jquery Bug Rendering Repeatable Fields Unusable

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

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
- 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 7:00 – 14:00 -
- 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 15:00 – 16:00 -

Supporter timezone: Europe/London (GMT+01:00)

This topic contains 7 replies, has 2 voices.

Last updated by jamesT-5 5 years, 5 months ago.

Assisted by: Nigel.

Author
Posts
#1155541

Hello,

I've recently updated all Toolset plugins to the new versions just released.

I have created a repeating custom field group "Materials Required" with 2 fields: Description and Quantity. This group is applied to a single post type: Tasks.

I created a new Cred Form and selected the repeatable group and auto generated the form (including the drop down to select which task it applies to). I placed the form directly into a page.

There are now 2 issues:

1. It is just displaying the form as if they were single fields with a submit button at the end (ie. no way to add repeating fields, missing a + icon to add more than one). I reverted the theme to WP default to check it wasn't a theme conflict, no luck.

2. When I now go into the backend to view the repeating group within Tasks, it's just stuck "Loading..." and in Inspect Console there are a couple of Jquery errors related to Cred Forms files. I have tried deleting the repeating group and the cred forms and re-creating, but it still doesn't work.

Only when I de-activate Toolset Forms, does it then work again and the Loading... bug is gone?

Please help! stuck unable to complete a project.

Thanks

James

#1155581

Hi Nigel,

Just to follow on from the chat earlier. I'm unable to submit any cred forms without a fatal error:

Fatal error: Uncaught Error: Call to undefined function get_current_screen() in /var/www/vhosts/createservers.co.uk/2017/rlm/wp-content/plugins/cred-frontend-editor/vendor/toolset/toolset-common/utility/condition/post_type/editor/is_block.php:67 Stack trace: #0 /var/www/vhosts/createservers.co.uk/2017/rlm/wp-content/plugins/cred-frontend-editor/vendor/toolset/toolset-common/utility/condition/post_type/editor/is_block.php(32): Toolset_Condition_Post_Type_Editor_Is_Block->get_post_type_by_current_screen() #1 /var/www/vhosts/createservers.co.uk/2017/rlm/wp-content/plugins/cred-frontend-editor/vendor/toolset/toolset-common/toolset-forms/classes/class.conditional.php(157): Toolset_Condition_Post_Type_Editor_Is_Block->is_met() #2 /var/www/vhosts/createservers.co.uk/2017/rlm/wp-content/plugins/cred-frontend-editor/vendor/toolset/toolset-common/toolset-forms/classes/class.conditional.php(121): WPToolset_Forms_Conditional->get_block_editor_form_selectors() #3 /var/www/vhosts/createservers.co.uk/2017/rlm/wp-content/plugins/cred-fro in /var/www/vhosts/createservers.co.uk/2017/rlm/wp-content/plugins/cred-frontend-editor/vendor/toolset/toolset-common/utility/condition/post_type/editor/is_block.php on line 67

I've added a basic form to submit a post here: hidden link

#1156098

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

Hi James

Seems like you are seeing that error because get_current_screen is available only on the backend and you are submitting a form on the front end, where it shouldn't be used.

I can't reproduce the error on my own sites, though, so I've passed a copy of your site to my colleagues for debugging, and I'll update you with their findings.

Regarding improving Forms for adding multiple RFGs, I discussed with the developers who have it as one of the main features that will get some attention "soon", but "soon" should be interpreted as within the next few months rather than any sooner.

It would likely have been done but for a detour in our roadmap to take on board Gutenberg-related changes.

Behind the scenes the development team are introducing changes which should make it quicker to iterate on changes and speed up development of such features going forward, but those introducing those changes themselves will occupy some time in the immediate future.

#1156141

Hi Nigel,

Thanks for the reply. I'm not sure what i'm supposed to do, it was working fine but since updating to the latest version the forms have stopped working? I've not put anything weird into the forms or any custom code (i don't know what get_current_screen is?)

Thanks

James

#1156168

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

Hi James

We have a few reports of this now and it is being addressed by the devs as I type.

We will hopefully be able to publish a fix for the forms error later today.

#1156231

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

Hi James

Types 3.2.1 was just published and should fix the issue, if you want to go ahead an update and test.

#1156423

Checking now Nigel, thanks for the quick fix!

#1156424

My issue is resolved now. Thank you!

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