Serve static content from a cookieless domain fail

The support forum is open for members only. To add a topic or reply in the forum, please login or register.

Support Forums Support Serve static content from a cookieless domain fail

This topic is: Resolved

Tagged: 

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #2579

    Sharon Hod
    Participant

    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.

    #2580

    Sharon Hod
    Participant

    I think I see the problem, just don’t know how to solve it –> http://d.pr/i/4hWI

    #2592

    Boaz
    Keymaster

    Hi Sharon,

    Unfortunately, we cannot support custom code changes.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.