WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How do I cache specific file in WordPress?

I have a file in a theme in WordPress and W3 Total cache. The file has a .php extension and is loading dynamic CSS from database. It takes too much time to load current settings from DB so it's slowing down page significantly.

How can I set W3 Total Cache so it caches the file?


migration rejected from webmasters.stackexchange.com Aug 21 '14 at 4:28

This question came from our site for pro webmasters. Votes, comments, and answers are locked due to the question being closed here, but it may be eligible for editing and reopening on the site where it originated.

closed as off-topic by Johannes Pille, shea, gmazzap, Wyck, Pieter Goosen Aug 21 '14 at 4:28

This question appears to be off-topic. The users who voted to close gave this specific reason:

If this question can be reworded to fit the rules in the help center, please edit the question.

If said file is loading WP environment at all? Without that I doubt it would be possible to cleanly cache it, maybe even then. I would question implementation in first place if it's that slow. – Rarst Feb 11 '14 at 20:58
Hi Rarst, it's a file that belongs to theme. I can hardly do anything about it. It has administration to change css... – greenleader Feb 12 '14 at 14:26