AbanteCart Community

Shopping Cart Operations => Support => Topic started by: cookie2363 on November 15, 2019, 10:04:57 AM

Title: Unable to add code snippet into head
Post by: cookie2363 on November 15, 2019, 10:04:57 AM
Hi all,
I want to add Trustpilot code snippet to the <head> element of the site but I can't seem to get anywhere.
Could someone please point me in the right direction. I Need to add the following code ( this is an example code, the actual code has my intregration key.)

<script>
(function(w,d,s,r,n){w.TrustpilotObject=n;w[n]=w[n]||function(){(w[n].q=w
[n].q||[]).push(arguments)};a=d.createElement(s);a.async=1;a.src=r;a.type
='text/java'+s;f=d.getElementsByTagName(s)[0];f.parentNode.insertBefore(a
,f)})(window,document,'script','://invitejs.trustpilot.com/tp.min.js
', 'tp');
tp('register', '#KEY#');
</script>
Title: Re: Unable to add code snippet into head
Post by: Basara on November 18, 2019, 12:25:10 AM
Hello.
Create HTML block and insert it to the header or header_top section in Layouts
https://abantecart.atlassian.net/wiki/spaces/AD/pages/12419073/HTML+Block
Title: Re: Unable to add code snippet into head
Post by: cookie2363 on November 20, 2019, 02:10:46 PM
When I do this it and click save the page redirects to "The page you requested cannot be found." and it doesn't save.
The script is Java so I'm thinking the system doesn't like this?
Title: Re: Unable to add code snippet into head
Post by: Basara on November 21, 2019, 05:31:57 AM
Hello.
Possible that this is server configuration issue related to mod_security php module https://abantecart.atlassian.net/wiki/spaces/AD/pages/3604484/Mod+security+403+406+error