1

In Drupal 8, I LOVE that there are default fields in Contact Forms for Name, Email, Subject, and Message...but in several of our forms those labels don't make sense.

For example, one form's primary use is to request an appointment, but I would like to use the Message field to ask if they have any other questions. Saying "Message" at the top of the box doesn't make sense, and I would like to still use the field but change the label to "Questions".

Is that possible to do without making another field and hiding the default field?

  • Not really an answer to your question, but because you are speaking of "several" forms, I'd suggest trying the really excellent Webform module instead, which allows this (and MUCH more) – Hudri Nov 15 '18 at 16:52
1

AFAICT each contact category has its own form ID, which means you can change it with hook_form_alter() in your theme or a custom module. Here's a tutorial about how to implement it, although there are other resources you can find: Learn how to change an existing Drupal form.

If you wanted to do it without coding then creating a new field and adjusting form and display for each contact category is the way to go.

As Hudri mentioned in a comment you could use Webform for a lot more control, including saving the responses in the database. If you don't need to keep record of the correspondence than Webform is probably an overkill.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.