コード例 #1
0
ファイル: users_log.php プロジェクト: TheReaCompany/pooplog
if (isset($_GET["un"])) {
    $user_name = urldecode($_GET["un"]);
}
if (isset($_GET["vote"])) {
    $filter_vote = $_GET["vote"];
}
if (isset($_POST["gdsr_filter"]) && $_POST["gdsr_filter"] == __("Filter", "gd-star-rating")) {
    $filter_vote = $_POST["gdsr_vote"];
    $page_id = 1;
}
$is_thumb = substr($vote_type, 3) == "thumb";
if (isset($_POST["gdsr_update"]) && $_POST["gdsr_update"] == __("Update", "gd-star-rating")) {
    $ips = $_POST["gdsr_item"];
    if (count($ips) > 0) {
        if (isset($_POST["gdsr_ip_ban"])) {
            $all_banned = gdsrAdmDB::get_all_banned_ips();
            $banned_ips = array();
            foreach ($all_banned as $ip) {
                $banned_ips[] = $ip->ip;
            }
            foreach ($ips as $ip) {
                if (!in_array($ip, $banned_ips)) {
                    gdsrAdmDB::ban_ip($ip);
                }
            }
        }
        if (isset($_POST["gdsr_delete_articles"])) {
            $page_id = 1;
            $xips = array();
            $del = $_POST["gdsr_delete_articles"];
            foreach ($ips as $ip) {
コード例 #2
0
_e("Record Id", "gd-star-rating");
?>
</th>
            <th scope="col"><?php 
_e("Type", "gd-star-rating");
?>
</th>
            <th scope="col"><?php 
_e("IP", "gd-star-rating");
?>
</th>
        </tr>
    </thead>
    <tbody>
<?php 
$rows = gdsrAdmDB::get_all_banned_ips(($page_id - 1) * $posts_per_page, $posts_per_page);
$tr_class = "";
foreach ($rows as $row) {
    echo '<tr id="post-' . $row->id . '" class="' . $tr_class . ' author-self status-publish" valign="top">';
    echo '<th scope="row" class="check-column"><input name="gdsr_item[]" value="' . $row->id . '" type="checkbox"></th>';
    echo '<td>' . $row->id . '</td>';
    echo '<td><strong>';
    switch ($row->mode) {
        case "S":
            echo "Single";
            break;
        case "M":
            echo "Masked";
            break;
        case "R":
            echo "Range";