The live chat icon is located under the side navigation and user bar, by default. The exact HTML that inserts the live chat button can be found in the navbar template.
Some of our customers have posted on the forum asking how they can hide the live chat status icon from support center visitors who are not logged in.

This can be done by applying a very simple modification to the template code.
In the administrator control panel, go to the templates section. Then, open up the navbar template (found under the “General” templates category).
In the navbar template code, find the following template code:
1
2
3
4
5
6
7
| <table border="0" cellspacing="0" cellpadding="3" width="100%">
<tbody>
<tr>
<td align="center">
<script src="<{$swiftpath}"><!--mce:0--></script></td>
</tr>
</tbody></table> |
And replace it with the following:
1
2
3
4
5
6
7
8
9
| <{if $_USER[loggedin] == true}>
<table border="0" cellspacing="0" cellpadding="3" width="100%">
<tbody>
<tr>
<td align="center">
<script src="<{$swiftpath}"><!--mce:1--></script></td>
</tr>
</tbody></table>
<{/if}> |
This modification wraps the template code which displays the live chat status icon in a conditional statement that asks: “Is this visitor logged in?” (<{if $_USER[loggedin] == true}>). If the answer is yes (true), then the live chat status icon is displayed to the visitor. If the answer is no (false), no icon is displayed in the visitor.
However, there is a caveat to this change. Because the visitor monitoring code is embedded in this live chat button (to save loading multiple objects when loading a page), you will no longer be able to monitor guest (not logged in) visitors on your support desk.
To work around this, you can add an else to the conditional statement that will output visitor tracking code if the visitor is not logged in:
1
2
3
4
5
6
7
8
9
10
11
12
13
| <{if $_USER[loggedin] == true}>
<table border="0" cellspacing="0" cellpadding="3" width="100%">
<tbody>
<tr>
<td align="center">
<script src="<{$swiftpath}"><!--mce:2--></script></td>
</tr>
</tbody></table>
<{else}>
<script src="”<{$swiftpath}"><!--mce:3--></script>
<{/if}> |
The code still asks “Is this visitor logged in?”. However, rather than loading nothing if the answer is no, visitor tracking code will be loaded.
The resulting functionality is:
- Visitors who are logged in to the support centre will see the live chat status icon, can be monitored and will be able to start a new chat
- Visitors who are not logged in to the support centre will not be able to see an icon, but can still be monitored and will be able to receive proactive chat request invitations from chat operations
This short guide is a good example of the power that can be tapped from the Kayako template system. Our customers think that the template system is incredibly easy to work with, allowing them to tailor their support desk with very little effort.