How do I change the Submit button text?

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

santhoshabraham created an issue. See original summary.

jrockowitz’s picture

Status: Active » Fixed
FileSize
92.61 KB

santhoshabraham’s picture

Great, Thank You!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

michael630angelo’s picture

Search. If we change the button text from “Submit” to “Search,” is there a way we can search for the name, for example, of a webform submission and then, edit/update its content?

It’s because I’d like to make a webform submission search and then edit/update its content, in an authenticated user perspective, not as an administrator.

Thanks so much for your help.

jrockowitz’s picture

Please post general support questions to https://drupal.stackexchange.com/questions/tagged/webforms

Vivek Panicker’s picture

Hi!
I would like to know if there is any way to do this with the Webform UI module disabled?

jenlampton’s picture

I'm also wondering the same thing. Thanks!

jrockowitz’s picture

To customize the submit button's label outside the Webform UI. You can append the webform_actions element to the YAML source.

actions:
  '#type': webform_actions
  '#title': 'Submit button(s)'
  '#submit__label': 'Send'
thomas.frobieter’s picture

To customize the submit button's label outside the Webform UI. You can append the webform_actions element to the YAML source.

If I do this in a Webform reference field (inside a Custom Block Type), the form actions are no longer printed out.

I've also tried just:

'#submit__label': 'Subscribe'
submit__label: 'Subscribe'
submit_label: 'Subscribe'

Same result :/

thomas.frobieter’s picture

Oh, sorry, my fault, it IS printed out, but the label stays the same.

jrockowitz’s picture

The Webform module's issue queue is for bugs, feature requests, and planning. Please post general support questions to Drupal Answers. You can also ask questions or help answer questions on the #webform channel on Drupal Slack.

The screenshot from #10 shows the Default submission data (YAML) which is not the same as the form's YAML source data.

FiNeX’s picture

@thomas.frobieter: did you solve this issue in some way or do we need to implement custom code?

thomas.frobieter’s picture

@FiNeX Sorry, I don't remember the result nor the affected project to have a look at :/

FiNeX’s picture

@thomas.frobieter: ok no problem. Thanks anyway :-)

whmedia’s picture

@FiNeX: did you found a solution? .. Thanks!

FiNeX’s picture

@whmedia: not yet, I'll return to this task in the coming months.