I recently enabled Cloudflare in conjunction with W3C Total Cache, as soon as Cloudflare kicked in the website encountered formatting issues and would not load any images.
Any idea what caused it? I disabled RocketLauncher and it didn’t help.
What is the domain? Without seeing what you’re seeing, I’m guess mixed content #communitytip will give you quick fix ideas to address mixed content errors.
Mixed content errors mean that your website is being loaded over HTTPS but some of the resources are being loaded over HTTP. To fix this you will need to edit your source code and change all resources to load over a relative path, or directly over HTTPS.
For example, if you load your images with a full URL:
<img src="http://example.com/image.jpg" />
You would want to change this to:
<img src="//example.com/image.jpg" />
By removing the http:, the browser will use whichever protocol the visitor is already using. An alternative option would be to enable the Automatic HTTPS Rewrites feature that can potentially fix these errors for you automatically. Do be aware that resources loaded by JavaScript or CSS will not be automatically rewritten and mixed content warnings will still appear.
Given that the website is built in wordpress, I can’t just edit all of the source code. Other than Automatic HTTPS Rewrites, are there any other ways to get this done?
Automatic rewrites will address a lot of the issues.
I’ve not used this plugin but many have and it seems to help, Flexible SSL for CloudFlare – Plugin WordPress | WordPress.org Italia. You can edit htaccess, htaccess is usually hidden. Make sure you can View Hidden Files. If it does not exist, create it. Add the following line to your .htaccess file: Header always set Content-Security-Policy: upgrade-insecure-requests