Page 1 of 1

Ticket ID in Email Subject

Posted: Thu Feb 17, 2011 12:35 pm
by chrisn0123
Hi all,

Just wondering if anybody knows how I can get the ticket id into the email subject of every
email that is sent out from hesk?

There's the *.txt files in languages/en/emails directory, such as "new_ticket.txt" etc, but they
are only the body of the email.

I would love to have "New ticket submitted - Ticket ID: ABCDEFGHI"

Spent ages looking, but cannot find out how! Searched and searched on here :)

I'm using Hesk 2.2 (latest as of Feb 2011)

Thanks all!
Chris

Re: Ticket ID in Email Subject

Posted: Sun Feb 20, 2011 7:25 pm
by Raven
I also had this in my old installation of Hesk but since upgrading to v2.2 can't seem to find the post explaining how it was done anymore....

Anyone know how to do this in v2.2?

Cheers

Re: Ticket ID in Email Subject

Posted: Mon Feb 21, 2011 1:40 pm
by Klemen
Here are a few posts about editing the e-mail subject:

viewtopic.php?f=13&t=1103&p=4608

viewtopic.php?t=1701&highlight=email+subject

viewtopic.php?t=2801&highlight=email+subject

Similar code can be found in all files that send out mail:
submit_ticket.php
reply_ticket.php
admin_reply_ticket.php
admin_submit_ticket.php
assign_owner.php
move_category.php

Re: Ticket ID in Email Subject

Posted: Mon Feb 21, 2011 2:14 pm
by Raven
Fantastic, thanks for that Klemen ;)

Re: Ticket ID in Email Subject

Posted: Fri Feb 25, 2011 9:19 am
by chrisn0123
Brilliant!!! Thanks for all of your help on this! :)

With your help I managed to change under admin_submit_ticket.php and submit_ticket.php
under "format e-mail message for customer"

@mail($tmpvar['email'],$hesklang['ticket_received'].' - TrackingID: '.$ticket['trackid'],$msg,$headers);

Emails come in like this now:
Ticket received - TrackingID: A4ZVQYBMJG

PERFECT! :D

The above can be changed for submit_ticket.php and all the reply ticket php files too. REMEMBER you
only change AFTER @mail($tmpvar['email'],$hesklang['ticket_received' <<<<CHANGE HERE>>>>>

Thanks all!

Take care,
Chris

Re: Ticket ID in Email Subject

Posted: Fri Feb 25, 2011 11:55 pm
by Raven
I made the following modifications and it is working perfectly :)

submit_ticket.php
Search for

Code: Select all

@mail($tmpvar['email'],$hesklang['ticket_received']
Replace entire line with

Code: Select all

@mail($tmpvar['email'],$hesklang['ticket_received'].' - TrackingID: '.$ticket['trackid'],$msg,$headers);
------------------------------------------------------------------------------------------------------------------------------------

reply_ticket.php
Search for

Code: Select all

@mail($email,$hesklang['new_reply_ticket']
Replace entire line with

Code: Select all

@mail($email,$hesklang['new_reply_ticket'].' - TrackingID: '.$ticket['trackid'],$msg,$headers);
------------------------------------------------------------------------------------------------------------------------------------

admin/admin_reply_ticket.php
Search for

Code: Select all

@mail($ticket['email'],$hesklang['new_reply_staff']
Replace entire line with

Code: Select all

@mail($ticket['email'],$hesklang['new_reply_staff'].' - TrackingID: '.$ticket['trackid'],$msg,$headers);
------------------------------------------------------------------------------------------------------------------------------------

admin/admin_submit_ticket.php
Search for

Code: Select all

@mail($tmpvar['email'],$hesklang['ticket_received']
Replace entire line with

Code: Select all

@mail($tmpvar['email'],$hesklang['ticket_received'].' - TrackingID: '.$ticket['trackid'],$msg,$headers);
------------------------------------------------------------------------------------------------------------------------------------

admin/assign_owner.php
Search for

Code: Select all

@mail($email,$hesklang['ticket_assigned_to_you']
Replace entire line with

Code: Select all

@mail($email,$hesklang['ticket_assigned_to_you'].' - TrackingID: '.$ticket['trackid'],$msg,$headers);
------------------------------------------------------------------------------------------------------------------------------------

admin/move_category.php
Search for

Code: Select all

@mail($email,$hesklang['ntmc']
Replace entire line with

Code: Select all

@mail($email,$hesklang['ntmc'].' - TrackingID: '.$ticket['trackid'],$msg,$headers);
------------------------------------------------------------------------------------------------------------------------------------

The above was already posted but I thought it may help other users who need a step-by-step guide on how to do this ;)

Re: Ticket ID in Email Subject

Posted: Tue Mar 01, 2011 2:36 pm
by chrisn0123
Thanks Raven! :D

Re: Ticket ID in Email Subject

Posted: Fri Mar 11, 2011 12:07 pm
by hollandsedrop
Hi friends,

When received new ticket coming e-mail ticket subject on email subject area

example: DEанонM
should be : DEĞİŞİM

I have charset problem this area. How can i fix it?

Thaks.

Re: Ticket ID in Email Subject

Posted: Fri Mar 11, 2011 5:46 pm
by Klemen
Are you using this modifications or the original files? If you use original ones please start a new topic with details on what language and encoding you usel

Re: Ticket ID in Email Subject

Posted: Sat Mar 12, 2011 8:44 am
by hollandsedrop
Original files (very small modification). My language is turkish and encoding charset=windows-1254

Thanks...