Re: [SMARTY] Storing variables in the cache

From: Date: Mon, 29 Aug 2005 15:57:45 +0000
Subject: Re: [SMARTY] Storing variables in the cache
References: 1  Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-12999@lists.php.net to get a copy of this message
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi, boots wrote: > Hi Ivo. I'm not exactly sure what you mean by this. Perhaps you are > thinking about cache_attrs on plugins? No, what I mean is something like this: if ($smarty->is_cached("test.tpl")) { $last_modified = $smarty->getVariable("test.tpl", "last_modified"); ) else { $last_modified = doSomeComplexStuffToDetermineLastModificationDate(); $smarty->setVariable("last_modified", $last_modified); } $smarty->render("test.tpl"); echo "Last modification = ".$last_modified; In other words, I not only want to store the template output in the cache, but also some meta data along with it. Greetings, Ivo - -- Ivo Jansch <ivo@ibuildings.nl> ibuildings.nl BV - information technology http://www.ibuildings.nl -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (MingW32) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFDEzB595NUnGFZm9cRAoZWAJ417qcAQvrr5OayQ5688LFHrrWOGwCg69xL NCbQRLHcF0rPo2NVZH+eORE= =uImj -----END PGP SIGNATURE-----

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