Example #1
0
 /**
  * Checks for the presence of blocks in the template
  * 
  * $param array $errorBlocks
  * $param array/bollean $parentBlocks
  *
  * @return bolean/void
  */
 protected function checkblock($errorBlocks, $parentBlocks = false)
 {
     if (empty($errorBlocks)) {
         return false;
     }
     if (is_array($parentBlocks)) {
         $error = array_intersect_key($errorBlocks, $parentBlocks);
     } else {
         $error = $errorBlocks;
     }
     if (!empty($error)) {
         foreach ($error as $bname => $v) {
             AbcError::domain('AbcTemplate: ' . $bname . ABC_INVALID_BLOCK);
         }
     }
 }