Esempio n. 1
0
 public function cachePages($pageIds)
 {
     include_once $this->sitePath . 'application/includes.inc.php';
     include_once ENGINE_PATH . 'class/classPageReCacher.php';
     include_once ENGINE_PATH . 'class/classReCacher.php';
     $reCacher = new ReCacher($this->sitePath, 'cache');
     $reCacher->setLogMode(2);
     $res = TRUE;
     if (is_array($pageIds)) {
         $tsize = sizeof($pageIds);
         for ($i = 0; $i < $tsize; $i++) {
             $res = $res && $reCacher->rebuildCachePageAdress($pageIds[$i]);
             //		$result = $reCacher->rebuildCachePageAdress($pageIds[$i]);
             //		if (!$result) $res = false;
             //sleep(10);
         }
     }
     return $res;
 }