Jump to:

10845 Posts in 2516 Topics by 1792 members

All other Modules

SilverStripe Forums » All other Modules » UserForms with SMTPMailer - problem with reply-to [SOLVED]

Discuss all other Modules here.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 491 Views
  • patitaflamenca
    Avatar
    Community Member
    2 Posts

    UserForms with SMTPMailer - problem with reply-to [SOLVED] Link to this post

    Hi there, I'm new to Silverstripe and hope someone can help me:

    I'm running Silverstripe locally using a WAMP server and therefore installed the smtpmailer module in order to send mails via my gmail account.
    I created a contact page using the userforms module.

    I'm trying to achieve the following:
    A user submits the form, entering "name", "Your Email" and "message"
    An email is sent to the site administrator. When replying to the email I'd like the user's email (from the "Your Email" field) to appear in the To field.

    I've set up the contact form to use the "Your Email" field from the form as the "From" field.

    There is no problem submitting the form and emails arrive fine. The problem is that the emails received have my gmail address (the one set up for "SMTP server username" in the smtpmailer settings) in the "From" field so when replying to the email I need to copy the user's email into the To field. Not ideal when emails are sent to other people who tend to overlook this.

    Any ideas are appreciated. Thanks

  • patitaflamenca
    Avatar
    Community Member
    2 Posts

    Re: UserForms with SMTPMailer - problem with reply-to [SOLVED] Link to this post

    Issue solved:

    After finding the article How to use Gmail as your SMTP server I changed my SMTPMailer settings to use the details of one of my websites (define('SMTPMAILER_SMTP_SERVER_ADDRESS', 'mail.mydomain.com'); etc.) and everything works perfectly.

    So the issue was Gmail related and had nothing to do with either Userforms or SMTPMailer.

    491 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.