Title: [Plugin: W3 Total Cache] Preloading page cache does not save pages
Last modified: August 20, 2016

---

# [Plugin: W3 Total Cache] Preloading page cache does not save pages

 *  Resolved [vicdahl](https://wordpress.org/support/users/vicdahl/)
 * (@vicdahl)
 * [14 years, 10 months ago](https://wordpress.org/support/topic/plugin-w3-total-cache-preloading-page-cache-does-not-save-pages/)
 * Hello!
 * I have configured W3 total cache to preload pages, but they do not seem to be
   saved in the cache. By looking in the web server log (see below) after triggering
   the wp_cron I have found out that the sitemap.xml is loaded by the web server
   and five pages then are requested by W3 Total Cache. However, counting the files
   in /wp-content/w3tc/pgcache before and after this session both results in 27,
   and loading the listed pages are just as slow as loading any not yet cached page.
   The saving of a page cache works when a real web browser hits the page; the number
   of files increases by one and next hit to that page is fast.
 * Has anyone experienced a similar problem? Any ideas for a solution?
 *     ```
       400.0.0.2 - - [13/Aug/2011:20:35:55 +0200] "GET /wp-cron.php?doing_wp_cron HTTP/1.1" 200 2 "-" "Opera/9.80 (X11; Linux i686; U; en-GB) Presto/2.9.168 Version/11.50"
       300.0.0.1 - - [13/Aug/2011:20:40:55 +0200] "GET /sitemap.xml HTTP/1.1" 200 12679 "-" "W3 Total Cache/0.9.2.3"
       300.0.0.1 - - [13/Aug/2011:20:40:56 +0200] "POST /wp-cron.php?doing_wp_cron HTTP/1.0" 200 2 "-" "WordPress/3.2.1; http://krischan.se"
       300.0.0.1 - - [13/Aug/2011:20:40:55 +0200] "GET /nationen/stipendier HTTP/1.1" 200 36561 "-" "W3 Total Cache/0.9.2.3"
       300.0.0.1 - - [13/Aug/2011:20:41:04 +0200] "GET /aktuellt/fotogalleri HTTP/1.1" 200 35878 "-" "W3 Total Cache/0.9.2.3"
       300.0.0.1 - - [13/Aug/2011:20:41:07 +0200] "GET /nationen/stadgar HTTP/1.1" 200 54306 "-" "W3 Total Cache/0.9.2.3"
       300.0.0.1 - - [13/Aug/2011:20:41:10 +0200] "GET /kontakt/marknadsforing HTTP/1.1" 200 37033 "-" "W3 Total Cache/0.9.2.3"
       300.0.0.1 - - [13/Aug/2011:20:41:13 +0200] "GET /huset/bostadsansokan HTTP/1.1" 200 35696 "-" "W3 Total Cache/0.9.2.3"
       ```
   
 * [http://wordpress.org/extend/plugins/w3-total-cache/](http://wordpress.org/extend/plugins/w3-total-cache/)

Viewing 8 replies - 1 through 8 (of 8 total)

 *  Thread Starter [vicdahl](https://wordpress.org/support/users/vicdahl/)
 * (@vicdahl)
 * [14 years, 10 months ago](https://wordpress.org/support/topic/plugin-w3-total-cache-preloading-page-cache-does-not-save-pages/#post-2242276)
 * I have found out that the saving of the pages works after replacing w3_http_get
   with file_get_contents in /wp-content/plugins/w3-total-cache/lib/W3/Plugin/PgCache.
   php on line 378:
 *     ```
       /**
        * Make HTTP requests and prime cache
        */
       foreach ($queue as $url) {
           //w3_http_get($url);
           file_get_contents($url);
       }
       ```
   
 * This solution works for me, but I don’t think it’s good to make changes to plugins
   as it will be reverted after update. Also, I suppose that the plugin’s function
   in some way is better than PHP’s internal, since otherwise it would be unnecessary.
 * I can’t see any differences in the requests in the web server log, apart from
   another user agent. I think it seems unlikely that the user agent makes the difference,
   but I don’t know what does.
 *  [doctorproctor](https://wordpress.org/support/users/doctorproctor/)
 * (@doctorproctor)
 * [14 years, 10 months ago](https://wordpress.org/support/topic/plugin-w3-total-cache-preloading-page-cache-does-not-save-pages/#post-2242297)
 * Yep, that was [my experience too](http://wordpress.org/support/topic/plugin-w3-total-cache-newbie-question-page-cache-only-after-load)…”
   Automatically prime the page cache” does not seem to work in spite of having 
   a compliant sitemap.xml…
 *  [toyNN](https://wordpress.org/support/users/toynn/)
 * (@toynn)
 * [14 years, 10 months ago](https://wordpress.org/support/topic/plugin-w3-total-cache-preloading-page-cache-does-not-save-pages/#post-2242302)
 * I’d previously posted about [this issue also](http://wordpress.org/support/topic/plugin-w3-total-cache-prime-page-cache-not-working?replies=3).
   I’ll give your workaround at try – though if its really a code bug it should 
   affect everyone – must not be too many folks using the Prime Cache option given
   that there has only be a few posts about it.
 *  [savvyharry](https://wordpress.org/support/users/savvyharry/)
 * (@savvyharry)
 * [14 years, 7 months ago](https://wordpress.org/support/topic/plugin-w3-total-cache-preloading-page-cache-does-not-save-pages/#post-2242426)
 * [@toynn](https://wordpress.org/support/users/toynn/)
 * in the link you provided, someone had come up with a mod… are you not using that?
 *  [Andreas](https://wordpress.org/support/users/andreasnrb/)
 * (@andreasnrb)
 * [14 years, 4 months ago](https://wordpress.org/support/topic/plugin-w3-total-cache-preloading-page-cache-does-not-save-pages/#post-2242450)
 * If you are still having cron sitemap problem could you be so kind to send a bug
   submission form from the Support page inside the plugin?
 *  Thread Starter [vicdahl](https://wordpress.org/support/users/vicdahl/)
 * (@vicdahl)
 * [14 years, 4 months ago](https://wordpress.org/support/topic/plugin-w3-total-cache-preloading-page-cache-does-not-save-pages/#post-2242451)
 * [@andreas](https://wordpress.org/support/users/andreas/) Nurbo
 * I’m still using version 0.9.2.3 with my modification above, now with wordpress
   3.3.1, and I think it’s working well. Some months ago when 0.9.2.4 was released
   I tried to update w3 total cache, but then the cache preload was even worse as
   it did not even try to load the pages according to the web server log.
 * Since the cache preload parts of w3 total cache seem to have changed a lot between
   0.9.2.3 and 0.9.2.4 I’m not sure a bug report from 0.9.2.3 would be useful. It
   would be nice to be able to update to the latest version though, so if you think
   it can be fixed I can try to submit a bug report, either from version 0.9.2.3
   or after trying to update to 0.9.2.4 again.
 *  [Jeroen @ Sea](https://wordpress.org/support/users/jeroen-1978/)
 * (@jeroen-1978)
 * [14 years, 4 months ago](https://wordpress.org/support/topic/plugin-w3-total-cache-preloading-page-cache-does-not-save-pages/#post-2242452)
 * [@vicdahl](https://wordpress.org/support/users/vicdahl/) [@andreas](https://wordpress.org/support/users/andreas/)
   nurbo
 * I agree with vicdahl, the function in 0.9.2.3 does work and stop functioning 
   in 0.9.2.4
 * For me [this](http://wordpress.org/support/topic/plugin-w3-total-cache-page-cache-not-preloading)
   worked and solved the problem.
 * Let me know if you need any help!
 *  Plugin Contributor [Frederick Townes](https://wordpress.org/support/users/fredericktownes/)
 * (@fredericktownes)
 * [14 years, 3 months ago](https://wordpress.org/support/topic/plugin-w3-total-cache-preloading-page-cache-does-not-save-pages/#post-2242453)
 * This is fixed in the next release.

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘[Plugin: W3 Total Cache] Preloading page cache does not save pages’ is
closed to new replies.

 * ![](https://ps.w.org/w3-total-cache/assets/icon-256x256.png?rev=1041806)
 * [W3 Total Cache](https://wordpress.org/plugins/w3-total-cache/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/w3-total-cache/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/w3-total-cache/)
 * [Active Topics](https://wordpress.org/support/plugin/w3-total-cache/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/w3-total-cache/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/w3-total-cache/reviews/)

 * 8 replies
 * 7 participants
 * Last reply from: [Frederick Townes](https://wordpress.org/support/users/fredericktownes/)
 * Last activity: [14 years, 3 months ago](https://wordpress.org/support/topic/plugin-w3-total-cache-preloading-page-cache-does-not-save-pages/#post-2242453)
 * Status: resolved