Prevent CloudFlare from Loading a js or Script

Sometimes CloudFlare / Rocket Loader can have problems with a script and hose it up. To have CloudFlare ignore a script try using the following flag which often resolves the issue:




Where as data-cfasync="false" is what you add to the script line.

Rocket Loader will still work for all other scripts.

Notes:

1. Adding this attribute within JS will not work to exclude the script from Rocket Loader.
2. The 'data-cfasync' attribute must be added before the 'src' attribute.
3. Rocket loader will recognize the tag when either single or double quotes are placed around the attribute value.


  • 122 Users Found This Useful

Was this answer helpful?

Related Articles

What is the location of curl?

Curl is located @ /usr/bin/curl

htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable

To solve “.htaccess pcfg_openfile: unable to check htaccess file, ensure it is readable” follow...

Set CORS header to Allow Access for any Incoming Domain

The following may be used to set to always set the CORS header for any incoming domains without...

Creating and Submitting a Google Sitemap

Creating a Google sitemap can be easy and beneficial. By using one, you are pushing a full list...

What is this Code 304 appearing in my stats?

304 is typically sent as a header if a visitor re-requests a document and the document has not...