Welcome! Log In Create A New Profile


How do I configure this properly in NGINX?

Posted by Evert 
How do I configure this properly in NGINX?
July 26, 2022 03:53AM
Hi all,

I want to add a Cloudflare-snippet to the end of all pages on a site. I am intending to use sub_filter for this:

sub_filter '</BODY>'
'<script defer src='https://static.cloudflareinsights.com/beacon.min.js' data-cf-beacon='{"token": "aaabbbccc55dd"}'></script>

How do I change this so that the various single and double quotes in that statement work properly? Do I escape them somehow, or is there another way to go?
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 77
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready