Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

osTicket v1.10 (stable) and Maintenance Release v1.9.15 are now available! Go get it now

cc and bcc on replies

My boss would like the ability to manually enter in email address into cc and bcc fields for ticket responses. Any help on how to add these fields to the ticket response page and have the responses emailed out correctly would be a great help!
«1

Comments

  • For RC4

    In include/staff/viewticket.inc.php ~ line 305 AFTER

                            <div style=\"margin-top: 3px;\">
    <label for=\"ticket_status\"><b>Ticket Status:</b></label>
    <?
    $checked=isset($info['ticket_status'])?'checked':''; //Staff must explicitly check the box to change status..
    if($ticket->isOpen()){?>
    <input type=\"checkbox\" name=\"ticket_status\" value=\"Close\" <?=$checked?> > Close on Reply
    <?}else{ ?>
    <input type=\"checkbox\" name=\"ticket_status\" value=\"Reopen\" <?=$checked?> > Reopen on Reply
    <?}?>
    </div>


    ADD

                            <div>
    <label for=\"carbon_copy\"><b>Cc:</b></label>
    <input type=\"text\" name=\"carbon_copy\" value=\"<?=$cc?>\" />
    <label for=\"blind_carbon_copy\"><b>Bcc:</b></label>
    <input type=\"text\" name=\"blind_carbon_copy\" value=\"<?=$bcc?>\" />
    </div>



    Then in scp/tickets.php ~ line 75 CHANGE

                //If no error...do the do.
    if(!$errors && ($respId=$ticket->postResponse($_POST['msg_id'],$_POST['response'],$_POST['signature'],$_FILES['attachment']))){


    TO

    			$cc = strip_tags($_POST['carbon_copy']);
    $bcc = strip_tags($_POST['blind_carbon_copy']);
    //If no error...do the do.
    if(!$errors && ($respId=$ticket->postResponse($_POST['msg_id'],$_POST['response'],$_POST['signature'],$_FILES['attachment'],true,$cc,$bcc))){



    Then in include/class.ticket.php ~ line 561 CHANGE

        function postResponse($msgid,$response,$signature='none',$attachment=false,$canalert=true){



    TO

        function postResponse($msgid,$response,$signature='none',$attachment=false,$canalert=true,$cc,$bcc){



    Then in include/class.ticket.php ~ line 613 AFTER

                    break;
    endswitch;
    $body = str_replace(\"%signature\",$signature,$body);


    ADD

    			$headers=\"\";
    if($cc) $headers.=\"Cc: \".$cc.\"\r\n\";
    if($bcc) $headers.=\"Bcc: \".$bcc.\"\r\n\";


    Then in include/class.ticket.php ~ line 620 CHANGE

                        $headers=\"MIME-Version: 1.0\n\" .


    TO

                        $headers.=\"MIME-Version: 1.0\n\" .
  • Great works fine for me.

    Was looking for this feature. Thanks for the mod.
  • thanks much for this. works great.
  • Thanks from me also, exactly what I wanted!
    :)

    New to osTicket but love it.
  • thx!

    Nothing to be add :)
    Great job man...
  • BCC and CC not working

    Hi,
    I have done as outlined in the steps above. However when I enter the CC and BCC addresses there are no emails going to those respective emails. :eek:
    Please tell me what I have done wrong!!
    Thanks :confused:
  • can you send me the 3 files mentioned above?

    [email]jpowers40828@gmail.com[/email]
  • Hi, I mailed them to you...:)
  • On the last step you put the add lines inside the } instead of after it.
  • Thanks very much. It works perfectly now!! cheers!:)
  • E-mails not being sent to CC or BCC or both

    Hi

    I am having an issue on this MOD. I have applied all codes mentioned before and the script works great. My only issue is that emails sent on CC & BCC are not being received by the users listed. The only email will be sent to the user that have opened the ticket. The funny thing is that in the email that is being sent to the user who opened the ticket you can see the CC, but the E-mail is not sent to CC.

    Can you help please?!
  • Have you checked the spam folder?
  • jpowers40828;7129 said:
    Have you checked the spam folder?
    No they are not coming into the spam folder. I have checked my email server logs to check whether they are being sent or not, but only the TO is being sent. I think I have some issues with the coding although I have copied all coding in this thread.

    I am using Kerio Mail Server

    Please HELP! to make it works cause I really need this mod. Is it possible to send you files to check them?
  • Sure, [email]jpowers40828@gmail.com[/email]

    You could make a ticket with my email address as well and do a carbon copy so I can see the email its sending that would be sweet too.
  • jpowers40828;7138 said:
    Sure, [email]jpowers40828@gmail.com[/email]

    You could make a ticket with my email address as well and do a carbon copy so I can see the email its sending that would be sweet too.
    I have emailed them to you and CC you on a current ticket to test. but i don't think it worked cause I was testing on my gmail as well.

    Thanks for your help
  • Attachments with bcc/cc

    Hi guys,

    I just recently discovered when I cc/bcc someone on an email, the attachment doesn't get actually attached to the email. Instead, the email contains this before the message:

    his is a multi-part message in MIME format.

    --==Multipart_Boundary_xc1620525debd108b501593f367d58e1fx
    Content-Type: text/plain; charset="utf-8"
    Content-Transfer-Encoding: 8bit

    and this after the message:

    --==Multipart_Boundary_xc1620525debd108b501593f367d58e1fx
    Content-Type: application/msword;
    name="SoftwareLicenceAgreement.rtf"
    Content-Disposition: attachment;
    filename="SoftwareLicenceAgreement.rtf"
    Content-Transfer-Encoding: base64

    e1xydGYxXGFkZWZsYW5nMTAyNVxhbnNpXGFuc2ljcGcxMDAwMFx1YzFcYWRlZmYwXGRlZmYwXHN0
    c2hmZGJjaDIyXHN0c2hmbG9jaDIyXHN0c2hmaGljaDIyXHN0c2hmYmkwXGRlZmxhbmcxMDMzXGRl
    ZmxhbmdmZTEwMzNcdGhlbWVsYW5nM
    .
    .
    .
    and much more, depending on what is in the attachment.

    If the attachment is an image, it goes through just fine, but if it is a text,rtf,doc etc. it will do the above.

    any idea? thanks much
  • So this just happens when you cc/bcc and its a text, rtf, or doc? It works fine when you don't cc/bcc and its a text, rtf, or doc?
  • thanks for asking. apologies, I made a mistake during testing the problem.

    if I cc/bcc someone with ANY attachment (text or image) it is not working

    it works just fine if I don't cc or bcc anyone and just send the attachment
  • Hey I changed my original post, the part that refers to class.ticket.php ~ line 613. I moved the part up some lines, hopefully that will help and added an extra line.
  • thanks very much for that. it is a bit better. now the behavior is as follows:

    - with attachment and cc or bcc or (cc and bcc) - now delivered fine to TO:, but no email delivered to cc/bcc at all

    - with attachment and NO cc/bcc - works fine
    - without attachment - works fine for all cases

    could it be that in class.ticket.php in the If (attachment area) u are assining the header as follows $headers="MIME-Version: 1.0\n" ....., instead of concantinating to the already existing $headers
  • Yeah, i forgot to have you throw the . in that.
  • Perfect. Thanks so much for your quick help.
  • the code doesn't work for me.
    could anyone help?
  • Email me your code. [email]jpowers40828@gmail.com[/email]
  • plz post the code ´cause my code doesn´t work.

    help plz.
  • Its on the first page of the thread. If you're having problems, shoot me an email with the modified files from osticket.

    [email]jpowers40828@gmail.com[/email]
  • Thanks for this mod.. I'll be trying it out later today and I'll let you know what I think after I get it working
  • Great Mod

    But I'm still having issues with the cc/bcc emails being sent out, just as in the internal notes posted.

    Maybe the smtp server is not handling it correctly? Also the manager that uses the program would like to see all messages posted internally and externally sent as an email to himself and the admin.

    Is there a mod for email messages on all posts, no matter if it is posted internally or externally.

    Please advise.
  • now it works but the mails have all the special characters wrong.
    i dont know what´s the problem.

    well i notice that in gmail and yahoo works fine but in hotmail all the special characters are wrong.

    help!
  • CC & BCC for Customer as well

    Hi,

    The mod is working fine but I wanted an additional feature related to this. I want to give the customer who is raising the ticket to be able to specify cc & bcc emails.

    Also, just wanted to confirm whether multiple emails can be given in cc & bcc fields? How should it be separated?
Sign In or Register to comment.