WebSite X5Help Center

 
Matthew S.
Matthew S.
User

Adding data to subject line in Contact Form  en

Auteur : Matthew S.
Visité 120, Followers 2, Partagé 0  

Is it possible to create a Contact Form that will insert one of the form fields into the email sent?

Example: The form subject line = Request for Product Information {#PRODUCT_INFO}

The field on the form would be named 'PRODUCT INFO' and the field value would be appended to the subject line.

The subject line setting seems static, but it would be helpful to make it dynamic by inserting a field value.

This helps with two things:

1) The emails will not stack up into a single thread so they don't get lost in GMail

2) The subject line is more descriptive and helpful

Here is the current contact form that I use:

https://matthewsohn.com/contact.php

The "Subject" drop-down is emailed in the body of the message but is not included in the subject of the email.

Any ideas and help would be greatly appreciated!

Matthew

Posté le
3 RéPONSES - 1 UTILES
Daniel W.
Daniel W.
User
Meilleur utilisateur du mois DEMeilleur utilisateur du mois EN

Here I found a German post from 2020 about the desired function with a solution, see

>> https://helpcenter.websitex5.com/fr/post/222199 (in German)

I haven't tested it myself, but perhaps Franz-Josef H. (Moderator) can also help here.

Maybe I'll do some tests and if it works, I'll write a little guide here.

Lire plus
Posté le de Daniel W.
Daniel W.
Daniel W.
User
Meilleur utilisateur du mois DEMeilleur utilisateur du mois EN

My test with the contact form and ReCaptcha didn't work, the send button remained pale and no emails arrived.

Maybe the PHP experts will test it with the current version of WebSiteX5.

Lire plus
Posté le de Daniel W.
Matthew S.
Matthew S.
User
Auteur

The link to the post: >> https://helpcenter.websitex5.com/fr/post/222199 (in German)

is very helpful.

Key point: use custom PHP code to replace fields with new values.

Thank you for identifying the PHP code file to modify: ../imemail/imEmailForm.php

Lire plus
Posté le de Matthew S.