Live Helper Chat support forum.. Forum is locked. New place for questions - Github Discussions
You are not logged in.
Pages: 1
Hello!
Our page embed code has suddenly stopped working, with no changes prior at our end:
Our code is:
[== Undefined ==]
<h3>Professional help for your loved one is available. Ask an addiction specialist now...</h3>
<div id="lhc_status_container_page"></div>
<script type="text/javascript">// <![CDATA[
var LHCChatOptionsPage = {};
LHCChatOptionsPage.opt = {};
function trackOffline() {
var po = document.createElement('script');
po.type = 'text/javascript'; po.async = true;
po.src = 'http://a.pixeltrax.net/px/?c=1f5b3e5a49d6c59';
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(po, s);
}
LHCChatOptionsPage.callback = {
online_chat_started_cb : function(inst) {
_gaq.push(['_trackEvent', 'LiveHelperChat', 'OnlineChatStartedPage', 'started']);
// Online chat started
trackOffline();
},
offline_request_cb:function(inst) {
_gaq.push(['_trackEvent', 'LiveHelperChat', 'OfflineChatStartedPage', 'offline_send']);
// Offline request was send
trackOffline();
}};
(function() { var po = document.createElement('script'); po.type = 'text/javascript'; po.async = true; po.src = '//abbeycarefoundation.com/livechat/index.php/chat/getstatusembed/(leaveamessage)/true'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(po, s); })();
// ]]></script>
...Remdex actually did this for us custom, to include the event tracking parameters.
Now, the standard page embed code from the config screen works just fine.
And, we have another site which uses this modified code, which has also stopped working:
Our host tells us there may have been a wordpress issue that needs a fix:
We have had a few reports of the same problem with WordPress based sites and them blocking the loading of Javascript.
Hopefully WordPress will push a fix out, that will allow Javascript to be loaded again but currently there has been no word from the Wordpress devs.
...are you aware of this at all, and is there any other fix we could use to get the page code working again, with the custom javascript?
Thank you
Offline
Here pasted code is correct, but viewing source on page, it seems like it was compressed or so. New line characters removed etc. Perhaps someone is compressing it.
Try in embed script remove "// Some comment" lines. then after compression even it should work. But it's definitely WP problem.
Offline
Hi, thanks for this, found it - it's a wordpress cdata bug due for fix in next major release:
https://core.trac.wordpress.org/tickets/major
(only red one on the page)
Hopefully helps anyone else with same issue. I will wait for release.
Thanks
Offline
Pages: 1