Jump to content

Adding purechat to prestashop


Recommended Posts

  • 1 month later...
  • 4 months later...
  • 5 months later...

hello

 

what kind of code you have to add to use it? 

the easiest thing: html block free, install it and paste your chate code there.

will work then.

 

Hi,

 

Do you have any Ideas if using CloudFlare, it won't load PureChat in Chrome, FireFox or Opera. You are meant to add data-cfasync=false to your script to bypass their Rocket Loader, html block and adding the modified script to the footer.tpl don't work.

 

Any Ideas?

 

Thanks in advance!

 

<script data-cfasync="false" src="/javascript.js"></script>

 

CloudFlare Instructions

 

Modified script

<script data-cfasync="false" type="text/javascript>(function () { var done = false; var script = document.createElement('script'); script.async = true; script.type = 'text/javascript'; script.src = 'https://widget.purechat.com/VisitorWidget/WidgetScript';; document.getElementsByTagName('HEAD').item(0).appendChild(script); script.onreadystatechange = script.onload = function (e) { if (!done && (!this.readyState || this.readyState == 'loaded' || this.readyState == 'complete')) { var w = new PCWidget({ c: 'de49bc9f-12b0-470d-a00d-**************', f: true }); done = true; } }; })();</script>

Original script

<script type='text/javascript'>(function () { var done = false; var script = document.createElement('script'); script.async = true; script.type = 'text/javascript'; script.src = 'https://widget.purechat.com/VisitorWidget/WidgetScript';; document.getElementsByTagName('HEAD').item(0).appendChild(script); script.onreadystatechange = script.onload = function (e) { if (!done && (!this.readyState || this.readyState == 'loaded' || this.readyState == 'complete')) { var w = new PCWidget({ c: 'de49bc9f-12b0-470d-a00d-************', f: true }); done = true; } }; })();</script>

Edited by osss (see edit history)
Link to comment
Share on other sites

×
×
  • Create New...