Re: [SMARTY] Caching & dynamic changing of cache_dir

From: Date: Fri, 28 Jun 2002 13:25:23 +0000
Subject: Re: [SMARTY] Caching & dynamic changing of cache_dir
References: 1 2 3  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-5087@lists.php.net to get a copy of this message
So you prepend your blockID to the cache_id. Remember how they can have "|" separators now? $cache_id = "$blockID|foo"; So if you want to clear all the caches for a particular block: $smarty->clear_cache($blockID); Or a particular cache id for a particular block: $smarty->clear_cache("$blockID|foo"); Monte Norbert Röcher wrote:
"Monte Ohrt" <monte@ispi.net> schrieb:
Give them different cache_id's if they are from separate cache
directories. Nope. It's not that simple. :-) To explain: The cache_dir is changend dynamicly to the name of the content blockID. The blockID is the ID of the content block, wich is passed to smarty by the app. This block maybe used by several different templates. So i need to be able to delete all cached templates of a specific blockID (without knowing all templates cache_id's), if the block's content gets changed or deleted. Regards, Norbert


« previous php.smarty.general (#5087) next »