$vstxt = "";
        }
    }
}
if ($move) {
    if ($userid == $ga['p1']) {
        $missfield = "p1missed";
    }
    if ($userid == $ga['p2']) {
        $missfield = "p2missed";
    }
    $db->query("UPDATE {$gpre}room SET {$missfield}=0 WHERE id={$roomid}");
    make_move($move, $userid, $roomid);
}
if ($gtype) {
    guess_type($gtype, $userid, $roomid);
}
if ($endturn) {
    end_turn($userid, $roomid);
}
print "<h1>{$gamename}</h1>";
if ($waittxt) {
    print "{$waittxt}";
} else {
    if ($defaultwin) {
        print "{$defaultwin}";
    } else {
        print "{$vstxt}{$wintxt}{$topturntxt}";
        if ($displayreplay) {
            if ($badreplaymsg) {
                print "You don't have enough money to play again.<br />";
function Fulltext_indexer_factory($path, &$index)
{
    $content_type = guess_type($path);
    if ($content_type == "text/plain") {
        return new Fulltext_TextIndexer($index);
    } elseif ($content_type == "text/html") {
        return new Fulltext_HtmlIndexer($index);
    }
    return NULL;
}
示例#3
0
    header('Location: http://' . $_SERVER['HTTP_HOST'] . dirname($_SERVER['REQUEST_URI']) . '/' . $alias . '/' . $book->default_link());
    exit;
}
if (!(list($compressed, $content) = $book->page($path, TRUE))) {
    header("Status: 404 Not Found");
    echo '<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">';
    echo '<html><head>';
    echo '<title>404 Not Found</title>';
    echo '</head><body>';
    echo '<h1>Not Found</h1>';
    echo '<p>The requested page was not found.</p>';
    echo '</body></html>';
    exit;
}
$catalog->page_hit($alias);
$content_type = guess_type($path);
$accept_compressed = strpos($_SERVER["HTTP_ACCEPT_ENCODING"], 'gzip') !== false;
if ($compressed) {
    if ($accept_compressed) {
        header('Content-Encoding: gzip');
        header('Content-Type: ' . $content_type);
        header('Vary: Accept-Encoding');
        echo $content;
    } else {
        $content = gzdecode($content);
        header('Content-Type: ' . $content_type);
        header('Content-Length: ' . strlen($content));
        header('Vary: Accept-Encoding');
        echo $content;
    }
} else {