/** * Write this cache object to handler * * @param Smarty_Internal_Template $_template template object * @param string $content content to cache * * @return boolean success */ public function write(Smarty_Internal_Template $_template, $content) { if (!$_template->source->recompiled) { if ($this->handler->writeCachedContent($_template, $content)) { $this->content = null; $this->timestamp = time(); $this->exists = true; $this->valid = true; if ($_template->smarty->cache_locking) { $this->handler->releaseLock($_template->smarty, $this); } return true; } } return false; }
/** * Write this cache object to handler * @param Smarty_Internal_Template $_template template object * @param string $content content to cache * @return boolean success */ public function write(Smarty_Internal_Template $_template, $content) { if (!$_template->source->recompiled) { if ($this->handler->writeCachedContent($_template, $content)) { $this->content = NULL; $this->timestamp = time(); $this->exists = TRUE; $this->valid = TRUE; $this->processed = FALSE; if ($_template->smarty->cache_locking) { $this->handler->releaseLock($_template->smarty, $this); } return TRUE; } $this->content = NULL; $this->timestamp = FALSE; $this->exists = FALSE; $this->valid = FALSE; $this->processed = FALSE; } return FALSE; }
/** * Write this cache object to handler * * @param Smarty_Internal_Template $_template template object * @param string $content content to cache * @return boolean success */ public function write(Smarty_Internal_Template $_template, $content) { if (!$_template->source->recompiled) { if ($this->handler->writeCachedContent($_template, $content)) { $this->timestamp = time(); $this->exists = true; $this->valid = true; return true; } } return false; }