Hi-
I've been updating data directly into the cms_content_props tables via an external script (to update content en mass). When i view the site however, it doesn't display the fresh data unless i log in and manually clear the cache.
Is there a way to clear or update the cache from an external script?
I'm not sure this is where to post this, but i hope someone can steer me in the right direction...
Thanks for any insight...
update/clear cache
Re: update/clear cache
Hi edented,
In the Event Manager you can call this UDT and let it clear the cache automatically.
Hope this helps, Rolf
You can create an user defined tag, called f.i. clear_cacheIs there a way to clear or update the cache from an external script?
Code: Select all
// Cut out of file: admin/siteprefs.php
{
global $gCms;
$contentops =& $gCms->GetContentOperations();
$contentops->ClearCache();
// $message .= lang('cachecleared');
}
Hope this helps, Rolf
- + - + - + - + - + - + -
LATEST TUTORIAL AT CMS CAN BE SIMPLE:
Migrating Company Directory module to LISE
Migrating Company Directory module to LISE
- + - + - + - + - + - + -
Re: update/clear cache
Thanks for the quick response- That helps a lot!
I see that i can make a page and include that UDT, then ping the url to clear the cache. It's a bit of a workaround, but as long as the page isn't deleted or overwritten, it should be okay.
cheers
-e
I see that i can make a page and include that UDT, then ping the url to clear the cache. It's a bit of a workaround, but as long as the page isn't deleted or overwritten, it should be okay.
cheers
-e