Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Archive /

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo

Changing "sender" in form - mail


Go to End


11 Posts   7007 Views

Avatar
Fuzz10

Community Member, 791 Posts

24 September 2007 at 11:57pm

Hi ,

I've browsed through the docs , but cannot seem to find a way to dynamically set the sender-emailaddress when using User generated forms.

Sorry if i overlooked something, but is this possible ?

Avatar
fws

Community Member, 3 Posts

26 February 2008 at 11:39am

is there no way to set the sender of forms ?

At the moment the form arrives with the subject as the title but the from field is empty

surly this should be set somewhere in a config file or in the main setup area of a form

Avatar
Willr

Forum Moderator, 5523 Posts

26 February 2008 at 9:47pm

I think you can set in the _config.php file at least Email::setAdminEmail()

Avatar
fws

Community Member, 3 Posts

27 February 2008 at 12:06am

Hi, yes I understand that but the form is not being sent from the admin its being sent from whoever fills it in.

We capture the email address and name in the contact form so why not use them in the mail headers ???

Avatar
insic2.0

Community Member, 16 Posts

21 April 2008 at 7:56pm

I want to change my email header too, anyone knows how to do it?

Avatar
insic2.0

Community Member, 16 Posts

21 April 2008 at 9:14pm

nevermind my post, i already get it. thanks

Avatar
potion_maker

Community Member, 36 Posts

12 August 2008 at 7:42am

So placed "Email::setAdminEmail('me@mysite.net');" in my _config.php file, but form emails still show up as sent from admin@myhost.com. Any ideas?

Avatar
Willr

Forum Moderator, 5523 Posts

12 August 2008 at 9:21am

do a global search on the whole project for "admin@myhost.com" and see if you have it anywhere

Go to Top