Customizing a contact 7 form so email address sent to is based on variables chosen

50 views Asked by At

Try to customize a contact 7 form so that the email goes out to different email address based on the values selected from the dropdowns. I'm not a programmer, just someone at home trying to build a website. Can someone help me with the code or point me towards it?

2

There are 2 answers

0
Tomi On

I'm not sure you can solve this without a bit of programming.

However I think if you want to do as little programming as possible, I'd set up as many identical contact forms as many email addresses you want to possibly send to..

After this you could write a little bit of JavaScript that changes the action attribute of the form element to the desired contact form when someone selects a specific option from a dropdown so that when they click submit,their data is sent to the form which emails the correct person.

This approach is probably not as nice as having 1 form and then writing some php to sort it out who it sends to but it requires less code and is less likely to break your site if it goes wrong.

0
Atif Tariq On

Please use the following code in form box,

[select your-recipient "CEO|[email protected]"
                    "Sales|[email protected]"
                    "Support|[email protected]"]

Then add the tag to mail "TO" filed, [your-recipient]