From: <on...@us...> - 2002-09-24 18:28:36
|
Update of /cvsroot/xoops/xoops-current/html/class In directory usw-pr-cvs1:/tmp/cvs-serv5985 Modified Files: xoopsmodule.php Log Message: no message Index: xoopsmodule.php =================================================================== RCS file: /cvsroot/xoops/xoops-current/html/class/xoopsmodule.php,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** xoopsmodule.php 22 Sep 2002 06:02:04 -0000 1.4 --- xoopsmodule.php 24 Sep 2002 18:28:33 -0000 1.5 *************** *** 674,682 **** } ! function useSmarty(){ ! if ( !isset($this->modinfo['use_smarty']) || $this->modinfo['use_smarty'] == 0 ) { ! return false; } - return true; } --- 674,691 ---- } ! function clearBlockCache(){ ! global $xoopsConfig; ! $block_arr = XoopsBlock::getByModule($this->mid); ! $count = count($block_arr); ! if ($count > 0) { ! $xoopsTpl = new XoopsTpl(); ! $xoopsTpl->setCaching(2); ! $xoopsTpl->setCacheDir(XOOPS_ROOT_PATH.'/cache'); ! $xoopsTpl->setCompileDir(XOOPS_ROOT_PATH.'/templates_c'); ! $xoopsTpl->setTemplateDir(XOOPS_ROOT_PATH.'/themes/'.$xoopsConfig['default_theme']); ! for ($i = 0; $i < $count; $i++) { ! $xoopsTpl->clear_cache('file:'.XOOPS_ROOT_PATH.'/themes/'.$xoopsConfig['default_theme'].'/blocks/'.$block_arr[$i]->getVar('btemplate'), 'block'.$block_arr[$i]->getVar('bid')) ! } } } |