Jump to:

17452 Posts in 4473 Topics by 1971 members

Archive

SilverStripe Forums » Archive » Email bcc's to sender?

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

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

Page: 1
Go to End
Author Topic: 1839 Views
  • StuM
    Avatar
    Community Member
    56 Posts

    Email bcc's to sender? Link to this post

    Hi All,

    I've just built emailing into my SS app, and there seems to be something strange going on with the emails. It sends OK, but the email address I have placed in the from field also receives a copy. I've got the same application on 2 servers, 1 testing and 1 production, and it's doing the same from both. I also tried sending an email through a basic php script using the same addresses, and this behaviour doesn't occur in that case.

    Have I missed something?

    The application I'm building will be sending hundreds or even thousands of emails a day and we're not wanting them all sent back to us as well, any ideas?

    here's the source code if it helps:

    public function sendEmail($ID)
       {
          $sub = DataObject::get_by_id('RegistrationSubmission', $ID);
          if ($sub)
          {
             $email = new Email_Template();
             $email->to = $sub->Email;
             $email->from = GFConst::email_from_name . '<' . GFConst::email_from . '>';
             $email->subject = GFConst::submission_subject;
             $email->ss_template = GFConst::submission_template;
             $email->populateTemplate($sub);
             $email->send();
          }
       }

  • StuM
    Avatar
    Community Member
    56 Posts

    Re: Email bcc's to sender? Link to this post

    Anybody? Is this a bug or the way it's supposed to work, if the former, how can I fix it, if the latter, how can I disable it?

    1839 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.