WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: W3 Total Cache] CDN populated, but not being used by site (10 posts)

  1. iamnick
    Member
    Posted 4 years ago #

    I'm using maxcdn. Lets say my site is foobar.com and the CDN cname is set to CDN.foobar.com.

    Here are my settings

    Page Caching Method: APC
    Minify Caching Method: APC
    DB Caching Method: APC
    CDN: Mirror
    Debug Mode: Enabled

    If I pull up the CDN.foobar.com directly in the browser, I can see the cached pages with the debug output in the source html. But pulling up foobar.com in the browser shows regular WP html (no cdn.foobar.com URLs or debug information).

    I have a feeling I'm missing a small step somewhere, what did I miss?

    thanks.

    http://wordpress.org/extend/plugins/w3-total-cache/

  2. iamnick
    Member
    Posted 4 years ago #

    I've also tried with the following settings with no success:

    Page Caching Method: disk enhanced
    Minify Caching Method: disk
    DB Caching Method: disk
    CDN: Mirror
    Debug Mode: Enabled

  3. Frederick Townes
    Member
    Posted 4 years ago #

    Unfortunately any other caching settings have nothing to do with the CDN. Do you actually have an account with a CDN provider?

  4. iamnick
    Member
    Posted 4 years ago #

    Like I said, I'm using MaxCDN. I've created an account, used the URL from the pull zone and created an A record like cdn.foobar.com that points to the MaxCDN URL.

    If I go to cdn.foobar.com (which is an A record to MaxCDN like cdn.foobar.netdna-cdn.com), I can see cached content with debug output (when I have debug enabled).

    So basically, the CDN has the content. Its the blog that isn't pulling it from the CDN or redirecting to the CDN.

  5. iamnick
    Member
    Posted 4 years ago #

    And to clarify, cdn.foobar.com is listed as the Replace default hostname with field.

  6. Frederick Townes
    Member
    Posted 4 years ago #

    Sorry I missed that. The CDN pulls it from your site and the plugin edits the cache files of your site to make images etc use the address configured in your settings (the CDNs address). So no, there's no redirect.

  7. iamnick
    Member
    Posted 4 years ago #

    Ok, so when I go to cdn.foobar.com directly, I can see that the css and js files now have URLs like http://cdn.foobar.com/wp-content/themes/headway-156/media/css/print.css. When I look at foobar.com, should not the css and js files have URLs like http://cdn.foobar.com/....? If so, the CDN is properly pulling my site, but the plugin does not seem to editing the cache files to change the URLs to http://cdn.foobar.com...

  8. Frederick Townes
    Member
    Posted 4 years ago #

    Then CDN is not enabled on general settings tab or you have not completed any minify settings or you are not matching any custom files on the CDN settings tab.

  9. iamnick
    Member
    Posted 4 years ago #

    On cdn.foobar.com, the HTML is all minified, so I *think* the minify options are ok.

    The CDN enable button is checked under general settings and type is set to origin pull (mirror).

    In general settings, minify enable is checked, and caching method is set to APC.

    In the minify settings, the following options are checked:

    HTTP compression (gzip)
    HTTP compression (msie6)
    Rewrite URL structure
    Automatically upload modified files
    max lifetime: 60 seconds
    update external files every: 60 seconds
    HTML settings: minify
    HTML settings: don't minify for admins
    HTML settings: inline css minification
    HTML settings: inline JS minification
    JS minify settings: Minify
    CSS minify settings: Minify

    JS file management is set to Default with no JS files added.
    CSS fiel management is set to Default with No CSS files added.

    Under CDN settings, these options are checked:
    Host wp-includes/ files
    Host active theme files
    Host minified CSS and JS files
    Host custom files
    wp-includes file types to upload: wlwmanifest.xml;*.css;*.js;*.gif;*.png;*.jpg
    Theme file types to upload: *.css;*.js;*.gif;*.png;*.jpg;*.ico
    Custom file list: favicon.ico

    I tried changing custom file list to * but that didn't change anything.

    Any ideas?

  10. Frederick Townes
    Member
    Posted 4 years ago #

    JS file management is set to Default with no JS files added.
    CSS fiel management is set to Default with No CSS files added.

    This means that no CSS or JS files are set to be minified. So unless you've added the paths to the files in your theme to the custom files section on the CDN settings tab, the plugin is not going to try to modify the URL to use the CDN for you.

    I tried changing custom file list to * but that didn't change anything.

    Don't do that, I don't even know what will happen if you do. I'm glad that it doesn't work. You just told the plugin to change all URLs to use the CDN, which is not a safe operation.

Topic Closed

This topic has been closed to new replies.

About this Topic