Contao Open Source CMS > Contao forum

Switch to german forum

Index > Feature request > Form sender taken from form data

Ben
Partner
Avatar
Posts: 2126
Atlanta, Georgia, United States
Whenever someone fills out a form on a TL site, it is sent from 'typolight@domain.com'. It would be a great addition if we could select one of the form fields (e-mail address Text field, for instance) as the sender of the e-mail. This way, the recipient of the e-mail can simply reply without having to change the To: field from typolight@domain.com to the senders e-mail address.

In System > Settings, I do have unchecked "Use SMTP to send mails" because my hosting provider does not allow me to use SMTP for web forms.
Last edited by Ben, 2007-02-13 15:38
2007-02-12 23:55
tinoo
User
Avatar
...or one step ahead:
the sender can choose the recipient email... For example: One contact form, containing a dropdownlist for choosing the recipient. This could be "General, Sale, Support" and so on. The user (=sender) can now choose to whom he wants to send the contact form. In the background TL replaces "General" by info@domain.tdl or "Sale" by sale@domain.tdl, an so on...
2007-02-13 07:42
Ben
Partner
Avatar
Posts: 2126
Atlanta, Georgia, United States
Tinoo - I agree that your request would be something nice to have, as well, so the form info can be directed to the appropriate person/address.
2007-02-13 15:37
leo
Administrator
Avatar
Posts: 7042
Wuppertal, Germany
Hi guys,

if your form contains a field called email, TYPOlight will use the value of this field as sender e-mail address. If the field does not contain a valid e-mail address, the fallback (typolight@domain.com) is used.

Regards
Leo
Last edited by leo, 2007-02-13 17:36
2007-02-13 17:30
Ben
Partner
Avatar
Posts: 2126
Atlanta, Georgia, United States
Weird, I use this in a form and it sends e-mails from typolight@domain.com:
- Field type = Text field
- Field name = email
- Field label = e-mail address
- Value = [null]
- Mandatory field = [checked]
- Input validation = E-mail address
- Maximum length = 0
- Access key = e
- Add submit button = [unchecked]

As mentioned above, my installation does not use an SMTP connection. Am I doing something wrong to cause it to send from typolight@domain.com even though I have a field named 'email'?
2007-02-13 17:40
leo
Administrator
Avatar
Posts: 7042
Wuppertal, Germany
Hi Ben,

I just came across a small bug in the form generator library which caused TYPOlight to always use the fallback sender e-mail address. Now that I have fixed it, the form generator works as intended.

Regards
Leo
2007-02-13 17:43
Ben
Partner
Avatar
Posts: 2126
Atlanta, Georgia, United States
Wow - thanks for the quick fix! I guess you can scratch my feature request from the list since it was already implemented. Any ideas on when version 2.2 will be released? (no pressure ... just curious)
2007-02-13 17:45
leo
Administrator
Avatar
Posts: 7042
Wuppertal, Germany
Hi Ben,

I am planning to release it by the end of this week.

Regards
Leo
2007-02-13 17:59
tinoo
User
Avatar
Hi Ben

iconBen:
Tinoo - I agree that your request would be something nice to have, as well, so the form info can be directed to the appropriate person/address.

Indeed! We would need just another multiline textfield in the backend, where we can list the mailadresses like this:

General|info@domain.tdl
Sale|sale@domain.tdl
Support|support@domain.tdl
Webmaster|webmaster@domain.tdl

and so on... The dropdownlist in the frontend form shows only "General", "Sale",... And the script then replaces the choosen recipient by his mailadress.

Could be a kind of spamblocker as well...
2007-02-14 09:50
Ben
Partner
Avatar
Posts: 2126
Atlanta, Georgia, United States
iconQuote:
Whenever someone fills out a form on a TL site, it is sent from 'typolight@domain.com'. It would be a great addition if we could select one of the form fields (e-mail address Text field, for instance) as the sender of the e-mail.

The initial request from this post has been implemented in version 2.2 of TYPOlight.
2007-02-28 20:31
seta
User
Avatar
Posts: 62
Gdansk, Poland
Hi there,

I would like to ask about that feature again.
I added field with name "email" but instead of having that email address in "FROM" I have it in "REPLY-TO".

Thx for help,
Pawel
2008-12-17 15:02
I have been working on this today - it seems that I too have the same issue - it is in the reply-to field rather than the from field. In the from field it uses the address from another site root in my Typolight Setup - not even the one from the root of the site that the form is in.

Anyone got any ideas about whether or not this is a bug?
2009-05-19 21:44