Email / Ticket Subject Field

Helpdesk for my helpdesk software

Moderator: mkoch227

Klemen
Site Admin
Posts: 10136
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

Don't fix if it ain't broke :wink:
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
southernmoney
Posts: 46
Joined: Sun May 10, 2009 3:44 pm

Emails Subject Flieds

Post by southernmoney »

Hi Klemen,

I would like to insert the client name again in the ticketing emails subject field. Please assist again as I have installed the latest version.

Regards.
Klemen
Site Admin
Posts: 10136
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

Have you tried using $tmpvar['name'] instead of $name?
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
southernmoney
Posts: 46
Joined: Sun May 10, 2009 3:44 pm

Emails Subject Field

Post by southernmoney »

Hi Klemen,

No! I do nothing without you approving. I know to little and trust none but you. Smile...

Please indicate what I should change to what and in which file [for staff and client all emails]

Appreciated.
Klemen
Site Admin
Posts: 10136
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

Since you are such a supporter of Hesk development, let it be :wink:

--> STAFF NOTIFICATION OF NEW TICKET

In the submit_ticket.php and in admin/admin_submit_ticket.php change:

Code: Select all

$hesklang['new_ticket_submitted']
to:

Code: Select all

$hesklang['new_ticket_submitted'].' by '.$ticket['name']
--> CUSTOMER NOTIFICATION OF NEW TICKET

In the submit_ticket.php and in admin/admin_submit_ticket.php change:

Code: Select all

$hesklang['ticket_received']
to:

Code: Select all

$hesklang['ticket_received'].' by '.$ticket['name']
--> STAFF NOTIFICATION OF NEW CUSTOMER REPLY

In the reply_ticket.php change:

Code: Select all

$hesklang['new_reply_ticket']
to:

Code: Select all

$hesklang['new_reply_ticket'].' by '.$ticket['name']
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
hollandsedrop
Posts: 90
Joined: Tue Dec 30, 2008 11:29 am

Post by hollandsedrop »

Hi Klemen,

this not work v2.2

help please?
Klemen
Site Admin
Posts: 10136
Joined: Fri Feb 11, 2005 4:04 pm

Post by Klemen »

Just tested it and works for me in v2.2
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
aknight
Posts: 3
Joined: Tue Nov 23, 2010 3:18 am

Re: Email / Ticket Subject Field

Post by aknight »

I am looking to add the ticket number to the subject line,

I replaced

Code: Select all

$hesklang['ticket_received']
with

Code: Select all

$hesklang['ticket_received'].' - '.$ticket['trackid']
but it did not work, what am I doing wrong?
Klemen
Site Admin
Posts: 10136
Joined: Fri Feb 11, 2005 4:04 pm

Re: Email / Ticket Subject Field

Post by Klemen »

You didn't mention which file you're editing, but you might want to see if using $trackingID helps.
Klemen, creator of HESK and PHPJunkyardWas this helpful? You can buy me a drink here Image

Image You should follow me on Twitter here

Help desk software | Cloud help desk | Guestbook | Link manager | Click counter | more PHP Scripts ...

Also browse for php hosting companies, read php books, find php resources and use webmaster tools
Lisaweb
Posts: 94
Joined: Sun Sep 25, 2011 3:23 pm

Re: Email / Ticket Subject Field

Post by Lisaweb »

Tried this in Version 2.3 and it didn't work. Oddly, it didn't seem to break it either. Just no change. So I'm going to try the other hack found here.

If this needs to be tweaked to work in 2.3, any suggestions would be appreciated. Thanks! :-)
Klemen wrote:Since you are such a supporter of Hesk development, let it be :wink:

--> STAFF NOTIFICATION OF NEW TICKET

In the submit_ticket.php and in admin/admin_submit_ticket.php change:

Code: Select all

$hesklang['new_ticket_submitted']
to:

Code: Select all

$hesklang['new_ticket_submitted'].' by '.$ticket['name']
--> CUSTOMER NOTIFICATION OF NEW TICKET

In the submit_ticket.php and in admin/admin_submit_ticket.php change:

Code: Select all

$hesklang['ticket_received']
to:

Code: Select all

$hesklang['ticket_received'].' by '.$ticket['name']
--> STAFF NOTIFICATION OF NEW CUSTOMER REPLY

In the reply_ticket.php change:

Code: Select all

$hesklang['new_reply_ticket']
to:

Code: Select all

$hesklang['new_reply_ticket'].' by '.$ticket['name']
- Lisa
Lisaweb
Posts: 94
Joined: Sun Sep 25, 2011 3:23 pm

Re: Email / Ticket Subject Field

Post by Lisaweb »

Ahah! I started thinking about it, and realized that I use the email piping feature in 2.3, so I need to make these changes in the /inc/mail/hesk_pipe.php file instead. Changed the following and it's working great:

Changed:

Code: Select all

/* Send e-mail */
hesk_mail($tmpvar['email'],$hesklang['ticket_received'],$msg);
to

Code: Select all

/* Send e-mail */
hesk_mail($tmpvar['email'],$hesklang['ticket_received'].' by '.$ticket['name'].' : '.$ticket['subject'],$msg);
Changed:

Code: Select all

/* Send e-mail to staff */
hesk_mail($autoassign_owner['email'],$hesklang['ticket_assigned_to_you'],$msg);
to:

Code: Select all

/* Send e-mail to staff */
hesk_mail($autoassign_owner['email'],$hesklang['ticket_assigned_to_you'].' by '.$ticket['name'].' : '.$ticket['subject'],$msg);

Changed:

Code: Select all

/* Send e-mail to staff */
$email=implode(',',$admins);
hesk_mail($email,$hesklang['new_ticket_submitted'],$msg);
to:

Code: Select all

/* Send e-mail to staff */
$email=implode(',',$admins);
hesk_mail($email,$hesklang['new_ticket_submitted'].' by '.$ticket['name'].' : '.$ticket['subject'],$msg);
- Lisa
Lisaweb
Posts: 94
Joined: Sun Sep 25, 2011 3:23 pm

Re: Email / Ticket Subject Field

Post by Lisaweb »

For better formatting, and to also add the ticket number, I changed all the email coding to the following. Worked great.

Code: Select all

hesk_mail($tmpvar['email'],$hesklang['ticket_received'].' ['.$ticket['trackid'].'] '.$ticket['name'].' ['.$ticket['subject'].']',$msg);

hesk_mail($autoassign_owner['email'],$hesklang['ticket_assigned_to_you'].' ['.$ticket['trackid'].'] '.$ticket['name'].' ['.$ticket['subject'].']',$msg);

hesk_mail($email,$hesklang['new_ticket_submitted'].' ['.$ticket['trackid'].'] '.$ticket['name'].' ['.$ticket['subject'].']',$msg);
Enjoy! :-D
- Lisa
hollandsedrop
Posts: 90
Joined: Tue Dec 30, 2008 11:29 am

Re: Email / Ticket Subject Field

Post by hollandsedrop »

Perfect!
Lisaweb
Posts: 94
Joined: Sun Sep 25, 2011 3:23 pm

Re: Email / Ticket Subject Field

Post by Lisaweb »

Thanks!

This is kinda fun. After tweaking, used another format that I like even better:

Code: Select all

hesk_mail($tmpvar['email'],$hesklang['ticket_received'].' [#'.$ticket['trackid'].'] '.$ticket['subject'].' ['.$ticket['name'].']',$msg);
Looks like:
Ticket received [#12A-PHA-U179] Ticket Subject [Submitter Name]

This format seemed the most easy to read in my email client. But this code is very easy to tweak into any number of combinations, to whatever one prefers. :-)
hollandsedrop wrote:Perfect!
- Lisa
promptcs
Posts: 2
Joined: Fri Nov 04, 2011 3:47 am

Re: Email / Ticket Subject Field

Post by promptcs »

this is really helpful but I would also like to edit the e-mail message. I would like to figure out how to make the email come in like this...

The metadata
from: <user submitted e-mail>
To: <the correct help desk staff
Subject <name> has submitted <ticketid> <subject>

The message
A new Ticket has been submitted by <name><e-mail address>

Ticket Number:<ticket number>
Ticket Subject:<subject>
Yours Issue:
<message>

Manage this ticket
<url of ticket>


*DO NOT REPLY TO THIS E-MAIL*
This is an automated e-mail message sent from our support system. Do not reply to this e-mail as we won't receive your reply, use the link above for proper communication!

Yours sincerely,
Post Reply