Example #1
0
 public static function error($sql, $backtrace)
 {
     print View::getRenderOneSSAEmpty('/site/error', array('sql' => $sql, 'backtrace' => $backtrace, 'PDO' => DB::$pdo->errorInfo()));
 }
Example #2
0
 public static function error($sql, $backtrace)
 {
     if (DEBUG == 0 && Funcs::$uri[0] != ONESSA_DIR) {
         header("HTTP/1.0 404 Not Found");
         DB::$error = true;
         View::$layout = 'main';
         View::render('site/error404');
     } elseif (DEBUG != 0 && Funcs::$uri[0] != ONESSA_DIR) {
         header("HTTP/1.0 404 Not Found");
         print View::getRenderEmpty('site/error', array('sql' => $sql, 'backtrace' => $backtrace));
     } else {
         print View::getRenderOneSSAEmpty('site/error', array('sql' => $sql, 'backtrace' => $backtrace));
     }
 }