I went into the database to manually change my user description. However, I noticed that the setting isn’t being changed by the webpage itself. If I go in through WP to change it in the admin, then the user description gets updated. This is a problem for me as I’m updating html code which gets parsed to characters when I update through the admin panel.
Is there a reason why making changes in the database doesn’t immediately reflect on the webpage itself?
I’d suspect the new disk cache functionality in WP 2.0. You can disable caching (temporarily or permanently) by adding this line to your wp-config.php
thanks, that did the trick! Do you know how long it caches for before updating again?
I would think you’d just leave that line in your wp-config.php permanently
As opposed to messing about with the wp-config.php file on a daily basis? Oy. Sheesh.
Okay. It can just live there forever. As I posted somewhere else, why do I need a cache anyway?
lawtai, last I checked the cache is updated either once a day or by specific WP events. However, there is a PHP constant for expiration time on the cache you can set:
Time value is in seconds. Set to whatever is desired (although a value of 1 is probably self-defeating).
vkaryl, WP 2.0 offers a wp_cache_flush() function, so there’s nothing stopping some plugin developer with free time from adding a little button in the admin pages which clears it. Oh, for some free time!
*laughing* Heh – free time? What’s THAT? Okay – that would be nice…. but I’m not by any means capable of producing it…. so I’ll either add in the exp time line or just leave it permanently disabled – as I said, why do I need it anyway? (The cache, I mean….)
On busy sites it can aid in response times, since a cached, static document residing on the server can be retrieved a lot quicker than a PHP document performing a bunch of sql queries and whatnot. It’s all about speed. Well, speed and load.
Even on let us say “leisurely” sites it can provide some improvement. But that’s up to the admin to decide…
Oh, WHAT a kind man you are tonight! Tell you what though, I think I’ll just do my “leisurely” thing until some wonderful plugin programmer produces that nifty li’l button….
Viper – you out there, buddy? Listening?
I love the idea of speeded up response time through using the new cache system. But in some cases, it’s taking me 20-30 minutes before I can see edited posts display the material I’ve added to them. This just doesn’t work for me.
last I checked the cache is updated either once a day or by specific WP events.
Would a “specific event” include publishing or republishing a post or publishing or deleting a comment? If so, perhaps the cache isn’t working properly in my case or there’s a bug in it since as I say I’m not seeing newly edited material.
I think I’ll have to disable the cache as well. Can Kafkaesqui or someone tell me whereabouts in the config.php file I’d place that code?
BTW, before upgrading to 2.0 I had wp-cache plugin installed until it started doing the same weird things (not allowing me to clear my cache & see updated web posts & web pgs.). I’m guessing that there must be operational similarities between the new wp cache & wp-cache.
Is there any way I can continue to use the cache but set the expiration time to a short enough time frame that it would allow me to see newly edited pgs?
When editing wp-config.php, place any of the suggested additions anywhere before this line:
Yes, events which should update the cache include publishing posts. However, I’m not educated enough on the built-in cache functionality to say right now which events update what, and what exactly is being cached.
CACHE_EXPIRATION_TIMEyou could try a few minutes or so, 120-180 seconds. Even that should provide a small benefit over non-caching (on busy sites). But again, as I’ve not completely investigated this feature of 2.0 I can’t say all of what is affected by
CACHE_EXPIRATION_TIME, or if it will help in your case.
Sorry if I appear dense (I just want to understand clearly what will happen) but, if I set that expiration duration that means that if the cache doesn’t clear itself immeidately & automatically ( as I believe it should) then within say 120 seconds I will definitely be able to see the changes to the post?
Or did I miss something?
I have just installed the cache-flush plugin ( http://www.xyooj.com/blog/plink/technical/31/plugin-to-flush-wordpress-cache/ ) because I was having problems when I edited posts it would pull up the cached version for me to edit instead of the version with the changes I had just made.
Kind of a pain to have to go ‘hit the button’ but much easier than going in and manually deleting the cache files.
My other wish is that the cache directory was not placed in the ‘wp-content’ directory since wp-content contains the files that should be backed up regularly and there is no need to backup the cache. Too bad it was not placed in a wp-cache directory at the same level as wp-content.
- The topic ‘Website not updated when database changes’ is closed to new replies.