Support › Forums › Support (Legacy) › Serve static content from a cookieless domain fail
Tagged: Atlanta
-
AuthorPosts
-
01/01/2017 at 0:25 #2579
In order to increase site speed i changed the serve of static content from a cookieless domain.
This is how:
1. I created a subdomain static.sharonhod.com pointing to public_html/sharonhod.com/wp-content
2. I added wp-cofing.php the following lines:
define(“WP_CONTENT_URL”, “http://static.sharonhod.com”);
define(“COOKIE_DOMAIN”, “sharonhod.com”);
define(“WP_PLUGIN_URL”, “http://static.sharonhod.com/plugins”);
3. I updated existing post content using phpMyAdmin:
UPDATE wp_posts SET post_content = REPLACE(post_content,’http://sharonhod.com/wp-content/uploads/’,’http://static.sharonhod.com/uploads/’)
4. Since Atlanta theme use Google fonts & font awesome for icons I added the following lines to .htaccess:
## EXPIRES CACHING ### ——————————————————————————
# | CORS-enabled images |
# ——————————————————————————<FilesMatch “\.(cur|gif|ico|jpe?g|png|svgz?|webp)$”>
SetEnvIf Origin “:” IS_CORS
Header set Access-Control-Allow-Origin “http://sharonhod.com” env=IS_CORS
</FilesMatch># ——————————————————————————
# | Web fonts access |
# ——————————————————————————# Allow access from all domains for web fonts
<FilesMatch “\.(eot|otf|ttc|ttf|woff)$”>
Header set Access-Control-Allow-Origin “http://sharonhod.com”
</FilesMatch>4. After all the modifications above still one problem.
Look at this url–> http://sharonhod.com/health-insurance/
This is how it’s supposed to look like (in the admin panel it’s shown ok) –> http://d.pr/i/MnQK
This is how it actually looks like when you load the page on browser –> http://d.pr/i/fiop
The Heebo Google font is not active and the site’s breadcrumbs style is wrong.Did I miss something?
Thanks.01/01/2017 at 1:44 #2580I think I see the problem, just don’t know how to solve it –> http://d.pr/i/4hWI
02/01/2017 at 15:11 #2592Hi Sharon,
Unfortunately, we cannot support custom code changes.
-
AuthorPosts
The forum ‘Support (Legacy)’ is closed to new topics and replies.