示例#1
0
 function error($message, $skin = 0)
 {
     global $TMPL;
     $TMPL['error'] = $message;
     if ($skin) {
         $TMPL["{$skin}_content"] = $this->do_skin('error');
         $TMPL['content'] = $this->do_skin($skin);
     } else {
         $TMPL['content'] = $this->do_skin('error');
     }
     $skin = new main_skin('wrapper');
     echo $skin->make();
     exit;
 }
示例#2
0
    $base = new base();
    $base->error($LNG['g_delete_install']);
}
// Check for hits in
require_once "{$CONF['path']}/sources/in.php";
$in = new in();
// Array containing the valid .php files from the sources directory
$action = array('admin' => 1, 'in' => 1, 'join' => 1, 'lost_pw' => 1, 'out' => 1, 'page' => 1, 'rankings' => 1, 'rate' => 1, 'search' => 1, 'stats' => 1, 'user_cpl' => 1);
// Require the appripriate file
if (isset($FORM['a']) && isset($action[$FORM['a']])) {
    $page_name = $FORM['a'];
} else {
    $page_name = 'rankings';
}
require_once "{$CONF['path']}/sources/{$page_name}.php";
$page = new $page_name();
// Display the page
$skin = new main_skin('wrapper');
echo $skin->make();
$DB->close();
// Print out debugging info, if necessary
if ($CONF['debug']) {
    echo '<div style="clear: both;">';
    foreach ($DB->queries as $value) {
        echo "<hr /><pre>{$value}</pre>";
    }
    echo '<hr /><pre>';
    print_r($_REQUEST);
    echo '</pre>';
    echo '</div>';
}