WP Super Cache not rewriting CDN url
-
Hi there,
I looked everywhere on this forum but I couldn’t find a solution.
I am trying to use cloudfront with WP Super Cache but the rewrite is not working. That mean that my images are still loading from wp-content/uploads/… instead of mydistribution.cloudfront.net/wp-content/uploads/…Here is my configuration: https://prntscr.com/9owrxj
My website is running on https. all http requests are redirected to https!The content of htaccess is as following:
# Remove ETags FileETag none # BEGIN Far Future Expiration <IfModule mod_expires.c> # Enable expirations ExpiresActive On # Default directive ExpiresDefault "access plus 1 hour" # My favicon ExpiresByType image/x-icon "access plus 1 hour" # Images ExpiresByType image/gif "access plus 1 hour" ExpiresByType image/png "access plus 1 hour" ExpiresByType image/jpg "access plus 1 hour" ExpiresByType image/jpeg "access plus 1 hour" # CSS ExpiresByType text/css "access plus 1 hour" # Javascript ExpiresByType application/javascript "access plus 1 hour" </IfModule> # END Far Future Expiration Plugin <IfModule mod_rewrite.c> RewriteCond %{HTTP_HOST} !^(.*)\.zigma\.ma$ [NC] RewriteRule ^(.*)$ https://www.zigma.ma/$1 [R=301,L] RewriteCond %{SERVER_PORT} 80 RewriteRule ^(.*)$ https://www.zigma.ma/$1 [R,L] </IfModule> # WordPress SEO - XML Sitemap Rewrite Fix RewriteEngine On RewriteBase / RewriteRule ^sitemap_index.xml$ /index.php?sitemap=1 [L] RewriteRule ^locations.kml$ /index.php?sitemap=wpseo_local_kml [L] RewriteRule ^geo_sitemap.xml$ /index.php?sitemap=geo [L] RewriteRule ^([^/]+?)-sitemap([0-9]+)?.xml$ /index.php?sitemap=$1&sitemap_n=$2 [L] RewriteRule ^([a-z]+)?-?sitemap.xsl$ /index.php?xsl=$1 [L] # END WordPress SEO - XML Sitemap Rewrite Fix # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress
Thank you very much
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘WP Super Cache not rewriting CDN url’ is closed to new replies.