- Edited
My post above #14 was actually the multiple bcc version using the arrays.. Did you try that?
As for the actually hidden bcc bit.. Not sure, can't say I've ever looked at one that I knew had a bcc.. you've got me interested now.
My post above #14 was actually the multiple bcc version using the arrays.. Did you try that?
As for the actually hidden bcc bit.. Not sure, can't say I've ever looked at one that I knew had a bcc.. you've got me interested now.
My post above #14 was actually the multiple bcc version using the arrays.. Did you try that?As for the actually hidden bcc bit.. Not sure, can't say I've ever looked at one that I knew had a bcc.. you've got me interested now.
Yes, its the array method that I tried and it worked, but of course now there is the BCC being shown that is the problem. (see picture attached)
Its very strange because I'm getting the BCC mail (the email account specified in the BCC receives the email), so thats working fine, but its also being shown to the main recipient, which kind of defeats the purpose of BCC :
Apparently the PEAR_Mail class doesn't support BCC: http://pear.php.net/bugs/bug.php?id=8047(http://pear.php.net/bugs/bug.php?id=8047)
So it looks like the BCC has to be added before the other headers.. Might just be an ordering issue, pretty cool that it send the email anyway!
Apparently the PEAR_Mail class doesn't support BCC: http://pear.php.net/bugs/bug.php?id=8047(http://pear.php.net/bugs/bug.php?id=8047)So it looks like the BCC has to be added before the other headers.. Might just be an ordering issue, pretty cool that it send the email anyway
My coding skills go as far as html and css, any other suggestions on a workaround? Should I just try changing the order and see what happens ?
Thanks!
Ok, if its just the order, I did a quick googly:
http://stackoverflow.com/questions/3797239/insert-new-item-in-array-on-any-position-in-php(http://stackoverflow.com/questions/3797239/insert-new-item-in-array-on-any-position-in-php)
$headers = array (
'From' => $this->getFromAddress(),
'To' => $to,
'Subject' => $subject,
'Date'=> date('D, d M Y H O'),
'Message-ID' => $messageId,
'X-Mailer' =>'osTicket Mailer');
/********** Custom BCC *******************/
$bcc = array('sales@you.com' => 'salesBCC@you.com','support@you.com' => 'supportBCC@you.com');
if($email=$this->getEmail()){ //can't use the getFromAddress function as that is a formatted string
$f = $email->getEmail();
// See if the senders address is in our array, if so, set the corresponding BCC address.
if(isset($bcc)) array_splice( $headers, 2, 0, array('Bcc' => $bcc ); // splice in at position 2 (numbering starts at 0)
}
Or, if that doesn't work, you can simply:
$headers = array ('From' => $this->getFromAddress(),'To' => $to);
$bcc = array('sales@you.com' => 'salesBCC@you.com','support@you.com' => 'supportBCC@you.com');
if($email=$this->getEmail()){ //can't use the getFromAddress function as that is a formatted string
$f = $email->getEmail();
// See if the senders address is in our array, if so, set the corresponding BCC address.
if(isset($bcc)) $headers = $bcc );
}
// Carry on adding the other headers..
$headers = $subject;
$headers= date('D, d M Y H O');
$headers = $messageId;
$headers = 'osTicket Mailer';
Option 2 worked for me :)
thanks!
Alrighht! Happy to help mate.
So this MOD will put all outgoing emails to SENT folder?Thank you
No .. According to the above ... all the outgoing mails are just saving in INBOX of another EMAIL ID. The other limitations we found are1) We can not insert multiple people in the TO section.2) We can not forward the mail through the ticket. (Suppose if the incoming mail needs to go to other person we can not forward it)3) No option to create a email from the OSticket itself, we can just send replies to the incoming emails.
1) Use Collaborators.2) Huh? 3) Huh? Every ticket updated can be configured to send an email.4) But wait you didn't have a 4! Please do not highjack other peoples threads. If you are having issue(s) please open your own thread so that it can be troubleshot for you. This thread is from August 2013. I would be shocked if you or dali were running version 1.7.Closing zombie thread with a head shot.