diff --git a/include/ajax.content.php b/include/ajax.content.php
index e97e96a5c3d1d894f5d7cacfad702c97ced25cf6..7f2bf7d7765cfe1b5fdaceba78166bf186d2f038 100644
--- a/include/ajax.content.php
+++ b/include/ajax.content.php
@@ -37,7 +37,7 @@ class ContentAjaxAPI extends AjaxController {
     function ticket_variables() {
 
         $content='
-<div style="width:600px;">
+<div style="width:680px;">
     <h2>Ticket Variables</h2>
     Please note that non-base variables depends on the context of use.
     <br/>
@@ -56,7 +56,9 @@ class ContentAjaxAPI extends AjaxController {
                     <tr><td>%status</td><td>Status</td></tr>
                     <tr><td>%priority</td><td>Priority</td></tr>
                     <tr><td>%dept</td><td>Department</td></tr>
-                    <tr><td>%assigned</td><td>Assigned staff or team (if any)</td></tr>
+                    <tr><td>%staff</td><td>Assigned/closing staff</td></tr>
+                    <tr><td>%team</td><td>Assigned/closing team</td></tr>
+                    <tr><td>%assigned</td><td>Assigned staff and/or team</td></tr>
                     <tr><td>%createdate</td><td>Date created</td></tr>
                     <tr><td>%duedate</td><td>Due date</td></tr>
                     <tr><td>%closedate</td><td>Date closed</td></tr>
@@ -67,8 +69,8 @@ class ContentAjaxAPI extends AjaxController {
                     <tr><td width="100">%message</td><td>Message (incoming)</td></tr>
                     <tr><td>%response</td><td>Response (outgoing)</td></tr>
                     <tr><td>%note</td><td>Internal/transfer note</td></tr>
-                    <tr><td>%staff</td><td>Staff\'s name (alert/notices)</td></tr>
-                    <tr><td>%assignee</td><td>Assigned staff</td></tr>
+                    <tr><td>%staff.name</td><td>Staff\'s name (alert/notices)</td></tr>
+                    <tr><td>%assignee</td><td>Assigned staff (assignment)</td></tr>
                     <tr><td>%assigner</td><td>Staff assigning the ticket</td></tr>
                     <tr><td>%url</td><td>osTicket\'s base url (FQDN)</td></tr>
                     <tr><td>%auth</td><td>Client authentication token</td></tr>
diff --git a/include/class.ticket.php b/include/class.ticket.php
index fc7eb1c520d45dfaab47ee3d7cd61db4f78f2eba..16d55865ef4e8b498709e04f35ce7b9b5f1621f9 100644
--- a/include/class.ticket.php
+++ b/include/class.ticket.php
@@ -419,6 +419,11 @@ class Ticket{
         return $assignees;
     }
 
+    function getAssigned($glue='/') {
+        $assignees = $this->getAssignees();
+        return $assignees?implode($glue, $assignees):'';
+    }
+
     function getTopicId() {
         return $this->topic_id;
     }
@@ -1106,8 +1111,8 @@ class Ticket{
 
 
         $search = array('/%id/','/%ticket/','/%email/','/%name/','/%subject/','/%topic/','/%phone/','/%status/','/%priority/',
-                        '/%dept/','/%assigned_staff/','/%createdate/','/%duedate/','/%closedate/','/%url/',
-                        '/%auth/', '/%clientlink/');
+                        '/%dept/','/%staff/','/%team/','/%assigned/','/%createdate/','/%duedate/','/%closedate/',
+                        '/%url/','/%auth/', '/%clientlink/');
         $replace = array($this->getId(),
                          $this->getExtId(),
                          $this->getEmail(),
@@ -1119,6 +1124,8 @@ class Ticket{
                          $this->getPriority(),
                          ($dept?$dept->getName():''),
                          ($staff?$staff->getName():''),
+                         ($team?$team->getName():''),
+                         $this->getAssigned(),
                          Format::db_daydatetime($this->getCreateDate()),
                          Format::db_daydatetime($this->getDueDate()),
                          Format::db_daydatetime($this->getCloseDate()),