Skip Navigation

[Resolved] How to change value of the Submit button in Relationship Forms

This thread is resolved. Here is a description of the problem and solution.

Problem:
How to change value of the Submit button in Relationship Forms

Solution:
you should use label attribute to customize the submit button text/label on post relationship forms.

For example:

[cred-form-submit label="your custom label"]

You can find proposed solution, in this case, with the following reply:
https://toolset.com/forums/topic/how-to-change-value-of-the-submit-button-in-relationship-forms/#post-913972

Relevant Documentation:

This support ticket is created 6 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.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10: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/Kolkata (GMT+05:30)

This topic contains 6 replies, has 2 voices.

Last updated by toolset-dave 6 years, 5 months ago.

Assisted by: Minesh.

Author
Posts
#913150

Hi,

I need to change the value of [cred-form-submit] in Relationship Forms instead of "Submit" to something different. I now that I can use [cred_field field='form_submit' value='My custom button'] in standard Toolset Forms, but this doesn´t work in Relationship ones.

#913315

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

To change the submit button text - Could you please try to add following code to your relationship form's Javascript editor section:

jQuery(document).ready(function($){
  $("input[name='cred-form-submit']").val("My custom button");
});

Feel free to change the text "My custom button" as per your need.

#913334

Hi Minesh,

thank you for the reply. It works nice. But can you add this to feature requests? You can easily change the value without JS code in Post and User forms, so it would be nice, to have it in Relationship ones.

#913359

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Glad to know that the workaround I shared works for you.

Yes - you are right. I will forward this as a new feature request for assessment.

#913362

Thank you, Minesh.

#913972

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Well - I just reopen this ticket to update you that when we debug this issue we found a way to display the label using shortcode [cred-form-submit]:

You should try to use "label" attribute - For example:

[cred-form-submit label="your custom label"]

Please once you use this - do not forget to remove the javascript code that I shared which you have added to your post relationship form.

#914554

Hi Minesh,

nice to hear that you have found a solution which works perfectly. It would be useful to find this in Documentation. Thanks.