function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
bombobombo 

Live Agent: "Send" Button in chat window

Hello,

I am currently trying to change the "Send" button that is displayed in a Live Agent Chat with a customer.
I found information in the documentation (http://www.salesforce.com/us/developer/docs/pages/Content/pages_compref_liveAgent_clientChatSendButton.htm), but I do not know where I can access the VF code to customize the chat window. Can anyone help me out? 


VictorFelisbinoVictorFelisbino
Under every button that you create for live agent you have the option to set your custom chat window.
You just need to edit the button and set your visualforce page under the Custom Chat Page field.

Creating your own chat window can be a little bit tricky, but will give you full control of how it looks and functions.

You can find a lot of it in the live agent developer guide documentation.

This guy also break it down pretty good in his blog http://iwritecrappycode.wordpress.com/2013/10/29/salesforce-live-agent-review-customization/
bomboobomboo
Hey there,

I simply don't get how I am supposed to add the Live Agent in to my visualforce page. I cannot find those components mentioned in the documentation, nor do I understand how I implement them to my custom chat window page! Can you please help me out, I'm feeling more and more desperate by now.
VictorFelisbinoVictorFelisbino
Do you have live agent active in your org? if so, you should start seeing the visualforce tags in developer console.

Here is a visualforce sample http://www.salesforce.com/us/developer/docs/live_agent_dev/Content/live_agent_visualforce_components_code_sample.htm

Let me know if this helps a bit and if you have any more questions
bomboobomboo
I already found that page before, and tried to use that code. The Live Agent is active in the org, yes! But somehow, nothing is shown, even if I simply paste that code into a custom visualforce page and open that site.

I do understand it right that those "<liveAgent:clientChatSaveButton/>" tags DO reference actual components, right? Somehow, I neither can't find any of those in SFDC, nor can I reference them in my IDE - it simply says "unkown tag". I have that feeling that I'm doing something dumb.

If you have any idea, please let me know! :)
VictorFelisbinoVictorFelisbino
Yes, those are actual components.
if you have everything configured correctly, this sample code should be working just fine.

Did you follow and did every step of the implementation guide?
https://seagate--csodev1.cs1.my.salesforce.com/help/pdfs/en/live_agent_impl_guide.pdf

i would suggest go over that again, im suspecting you have some permission or something simple missing. It always come down to a checkbox with salesforce... lol
bomboobomboo

Umm, okay - the thing is, I did not set up the live agent in that org, so I cannot really tell if it was done correctly. It is working fine though, I did test the chat window by myself.
 

The current error showing up is "Organization ID must be set", so I guess after pasting that code, there is some additional information that I have to put in?

 

Thank you so much already for your help!

VictorFelisbinoVictorFelisbino
you need to create a new page that will initiate your chat. The previous code i gave you is just for the chat window

in the new page, copy and paste the following code:

go to customize > live agent > deployments
click in the existing deployment name, this should provide you a deployment code, copy and paste that to the visualforce page

go to customize > live agent > chat buttons & invitations > click in the button that you want
copy and paste the chat button code to your page.

include the new page to your site

This now should give you a button that you can click and start your chat.

Also, that is the only place i can remeber you would need the correct og ids...
bomboobomboo

This does not work at all. Let's keep it basic: before I try to build that custom page, let's try to enable a page where the Live Agent is being shown.

What I did:

Created a page that had the code from the existing deployment in it (the first step you referenced). Then, I added the code from the second part you referenced. That should have resulted in a button that I could click to open a standard Live Agent window, shouldn't it? Because well, nothing happend.

VictorFelisbinoVictorFelisbino
Here is a sample code: this has more than you need for now, but its commented and you can remove what you dont need, just replace the button and the deployment code with yours

Welcome!

Thank you for contacting customer support.
bomboobomboo
Erm, you might've copied the wrong part - there's no code shown :(.

VictorFelisbinoVictorFelisbino
Sorry about that, im just now seeing this.
This works on my test page:
just change the id's to match yours:

<h3>Standard Chat Button - Hard coded button ID - Not dependent on Queue status</h3><br />
<a id="liveagent_button_online_57330000000LkQ2" href="javascript://Chat" style="display: none;" onclick="liveagent.startChat('57330000000LkQ2')">AMER - Online Chat Content</a><br />
<div id="liveagent_button_offline_57330000000LkQ2" style="display: none;">AMER - Offline Chat Content </div><script type="text/javascript">
if (!window._laq) { window._laq = []; }
window._laq.push(function(){liveagent.showWhenOnline('57330000000LkQ2', document.getElementById('liveagent_button_online_57330000000LkQ2'));
liveagent.showWhenOffline('57330000000LkQ2', document.getElementById('liveagent_button_offline_57330000000LkQ2'));
});</script>

<!-- Deployment -->
<script type='text/javascript' src='https://c.la1s1.salesforceliveagent.com/content/g/deployment.js'></script>
<script type='text/javascript'>
liveagent.init('https://d.la1s1.salesforceliveagent.com/chat', '57230000000DM6L', '00D00000000hhzl');
</script>

Ponni Priyadharshni PuliyurudaiyanPonni Priyadharshni Puliyurudaiyan

I get the same error "Organization ID must be set" - when I tried to create a new VF page with the code from here - https://developer.salesforce.com/docs/atlas.en-us.live_agent_dev.meta/live_agent_dev/live_agent_visualforce_components_code_sample.htm. Not sure which part I am missing, as I dont know where org ID is referred in the whole page here. 

Please let me know if anything needs to be done apart from the code.