I have Specific Requirement from my client that when ever - Customer submits theAfter customer registers his case through the WebToCase - he will receive anand automated email (With consists of the Case Number and a hyperlinkis sent to the Live Chat)him. The hyperlinkIn this email there should initiatebe an hyperlink - which initiates the live chat for the specific existing case - automaticallywith available agent. AndFrom agent shouldside- when he accepts the chat- he needs to get athe existing case record window withon his screen. This is the details ofrequirement. I'm trying to put the existing Case Recordbutton and deployment code in the HTML email Template. PleaseBut it is not working. Someone please help me to work onresolve this requirementissue.
Below is the code that I'm trying to use in the email template.
<!-- Button Code -->
<a id="liveagent_button_online_582f000000000RK" href="javascript://Chat" style="display: none;" onclick="liveagent.startChat('582f000000000RK')" > CLick Here</a>
<div id="liveagent_button_offline_582f000000000RK" style="display: none;"> Sorry No Agent Available </div>
<script type="text/javascript">
if (!window._laq) { window._laq = []; }
window._laq.push(function(){liveagent.showWhenOnline('582f000000000RK', document.getElementById('liveagent_button_online_582f000000000RK'));
liveagent.showWhenOffline('582f000000000RK', document.getElementById('liveagent_button_offline_582f000000000RK'));})
</script>
<-- Deployment Code -->
<script type='text/javascript' src='https://c.la4-c8ch-iad.salesforceliveagent.com/content/g/js/40.0/deployment.js'></script>
<script type='text/javascript'>
<!-- liveagent.addCustomDetail('Case Number', '00001006'); -->
liveagent.addCustomDetail('Case Number', '{!Case.caseNumber}');
liveagent.findOrCreate('Case').map('CaseNumber','Case Number',true,true,true).saveToTranscript('CaseId').showOnCreate();
liveagent.init('https://d.la4-c8ch-iad.salesforceliveagent.com/chat', '582c0000000Cpya', '00Dk0000009w6Y7');
</script>