Esempio n. 1
0
                    @unlink($filepath . $icon_small['name'] . ".tmp");
                    $error = $_language->module['format_incorrect'];
                    die('<b>' . $error . '</b><br /><br /><a href="admincenter.php?site=squads&amp;action=edit&amp;squadID=' . $id . '">&laquo; ' . $_language->module['back'] . '</a>');
                }
            }
        } else {
            echo $_language->module['information_incomplete'];
        }
    } else {
        echo $_language->module['transaction_invalid'];
    }
}
if (isset($_POST['saveedit'])) {
    $CAPCLASS = new Captcha();
    if ($CAPCLASS->check_captcha(0, $_POST['captcha_hash'])) {
        if (checkforempty(array('name'))) {
            $games = implode(";", $_POST['games']);
            safe_query("UPDATE " . PREFIX . "squads SET gamesquad='" . $_POST['gamesquad'] . "', games='" . $games . "', name='" . $_POST['name'] . "', info='" . $_POST['message'] . "', displayed='" . $_POST['displayed'] . "' WHERE squadID='" . $_POST['squadID'] . "' ");
            $filepath = "../images/squadicons/";
            $icon = $_FILES['icon'];
            $icon_small = $_FILES['icon_small'];
            $id = $_POST['squadID'];
            if ($icon['name'] != "") {
                move_uploaded_file($icon['tmp_name'], $filepath . $icon['name'] . ".tmp");
                @chmod($filepath . $icon['name'] . ".tmp", 0755);
                $getimg = getimagesize($filepath . $icon['name'] . ".tmp");
                $pic = '';
                if ($getimg[2] == IMAGETYPE_GIF) {
                    $pic = $id . '.gif';
                } elseif ($getimg[2] == IMAGETYPE_JPEG) {
                    $pic = $id . '.jpg';
Esempio n. 2
0
            }
            safe_query("INSERT INTO " . PREFIX . "faq ( faqcatID, date, question, answer, sort ) values( '{$faqcat}', '" . time() . "', '{$question}', '{$answer}', '1' )");
        } else {
            echo $_language->module['information_incomplete'];
        }
    } else {
        echo $_language->module['transaction_invalid'];
    }
} elseif (isset($_POST['saveedit'])) {
    $faqcat = $_POST['faqcat'];
    $question = $_POST['question'];
    $answer = $_POST['message'];
    $faqID = $_POST['faqID'];
    $CAPCLASS = new Captcha();
    if ($CAPCLASS->check_captcha(0, $_POST['captcha_hash'])) {
        if (checkforempty(array('question', 'message'))) {
            safe_query("UPDATE " . PREFIX . "faq SET faqcatID='{$faqcat}', date='" . time() . "', question='{$question}', answer='{$answer}' WHERE faqID='{$faqID}' ");
        } else {
            echo $_language->module['information_incomplete'];
        }
    } else {
        echo $_language->module['transaction_invalid'];
    }
}
if (isset($_GET['action'])) {
    if ($_GET['action'] == "add") {
        $ergebnis = safe_query("SELECT * FROM " . PREFIX . "faq_categories ORDER BY sort");
        $faqcats = '<select name="faqcat">';
        while ($ds = mysql_fetch_array($ergebnis)) {
            $faqcats .= '<option value="' . $ds['faqcatID'] . '">' . getinput($ds['faqcatname']) . '</option>';
        }
Esempio n. 3
0
    if ($CAPCLASS->check_captcha(0, $_POST['captcha_hash'])) {
        if (checkforempty(array('name', 'email'))) {
            safe_query("INSERT INTO " . PREFIX . "contact ( name, email, sort )\n\t            values( '{$name}', '{$email}', '1' )");
        } else {
            echo $_language->module['information_incomplete'];
        }
    } else {
        echo $_language->module['transaction_invalid'];
    }
} elseif (isset($_POST['saveedit'])) {
    $name = $_POST['name'];
    $email = $_POST['email'];
    $contactID = $_POST['contactID'];
    $CAPCLASS = new Captcha();
    if ($CAPCLASS->check_captcha(0, $_POST['captcha_hash'])) {
        if (checkforempty(array('name', 'email'))) {
            safe_query("UPDATE " . PREFIX . "contact SET name='{$name}', email='{$email}' WHERE contactID='{$contactID}' ");
        } else {
            echo $_language->module['information_incomplete'];
        }
    } else {
        echo $_language->module['transaction_invalid'];
    }
}
if (isset($_GET['action'])) {
    if ($_GET['action'] == "add") {
        $CAPCLASS = new Captcha();
        $CAPCLASS->create_transaction();
        $hash = $CAPCLASS->get_hash();
        echo '<h1>&curren; <a href="admincenter.php?site=contact" class="white">' . $_language->module['contact'] . '</a> &raquo; ' . $_language->module['add_contact'] . '</h1>';
        echo '<form method="post" action="admincenter.php?site=contact" name="post">
Esempio n. 4
0
    if ($CAPCLASS->check_captcha(0, $_POST['captcha_hash'])) {
        if (checkforempty(array('faqcatname'))) {
            safe_query("INSERT INTO " . PREFIX . "faq_categories ( faqcatname, description, sort ) values( '{$faqcatname}', '{$description}', '1' )");
        } else {
            echo $_language->module['information_incomplete'];
        }
    } else {
        echo $_language->module['transaction_invalid'];
    }
} elseif (isset($_POST['saveeditcat'])) {
    $faqcatname = $_POST['faqcatname'];
    $description = $_POST['message'];
    $faqcatID = $_POST['faqcatID'];
    $CAPCLASS = new Captcha();
    if ($CAPCLASS->check_captcha(0, $_POST['captcha_hash'])) {
        if (checkforempty(array('faqcatname'))) {
            safe_query("UPDATE " . PREFIX . "faq_categories SET faqcatname='{$faqcatname}', description='{$description}' WHERE faqcatID='{$faqcatID}' ");
        } else {
            echo $_language->module['information_incomplete'];
        }
    } else {
        echo $_language->module['transaction_invalid'];
    }
}
if (isset($_GET['action'])) {
    if ($_GET['action'] == "addcat") {
        $CAPCLASS = new Captcha();
        $CAPCLASS->create_transaction();
        $hash = $CAPCLASS->get_hash();
        $_language->read_module('bbcode', true);
        eval("\$addbbcode = \"" . gettemplate("addbbcode", "html", "admin") . "\";");
Esempio n. 5
0
}
if (isset($_POST['save'])) {
    $CAPCLASS = new Captcha();
    if ($CAPCLASS->check_captcha(0, $_POST['captcha_hash'])) {
        if (checkforempty(array('language', 'lang', 'alt'))) {
            safe_query("INSERT INTO " . PREFIX . "news_languages ( language, lang, alt ) values( '" . $_POST['language'] . "', '" . $_POST['lang'] . "', '" . $_POST['alt'] . "' ) ");
        } else {
            echo $_language->module['information_incomplete'];
        }
    } else {
        echo $_language->module['transaction_invalid'];
    }
} elseif (isset($_POST['saveedit'])) {
    $CAPCLASS = new Captcha();
    if ($CAPCLASS->check_captcha(0, $_POST['captcha_hash'])) {
        if (checkforempty(array('language', 'lang', 'alt'))) {
            safe_query("UPDATE " . PREFIX . "news_languages SET language='" . $_POST['language'] . "', lang='" . $_POST['lang'] . "', alt='" . $_POST['alt'] . "' WHERE langID='" . $_POST['langID'] . "'");
        } else {
            echo $_language->module['information_incomplete'];
        }
    } else {
        echo $_language->module['transaction_invalid'];
    }
} elseif (isset($_GET['delete'])) {
    $CAPCLASS = new Captcha();
    if ($CAPCLASS->check_captcha(0, $_GET['captcha_hash'])) {
        safe_query("DELETE FROM " . PREFIX . "news_languages WHERE langID='" . $_GET['langID'] . "'");
    } else {
        echo $_language->module['transaction_invalid'];
    }
}
Esempio n. 6
0
                rename($filepath . $rank['name'], $filepath . $file);
                safe_query("UPDATE " . PREFIX . "forum_ranks SET pic='{$file}' WHERE rankID='{$id}' ");
            }
        } else {
            echo $_language->module['information_incomplete'];
        }
    } else {
        echo $_language->module['transaction_invalid'];
    }
} elseif (isset($_POST['saveedit'])) {
    $rank = $_POST['rank'];
    $min = $_POST['min'];
    $max = $_POST['max'];
    $CAPCLASS = new Captcha();
    if ($CAPCLASS->check_captcha(0, $_POST['captcha_hash'])) {
        if (checkforempty(array('min', 'max'))) {
            $ergebnis = safe_query("SELECT * FROM " . PREFIX . "forum_ranks ORDER BY rankID");
            $anz = mysql_num_rows($ergebnis);
            if ($anz) {
                while ($ds = mysql_fetch_array($ergebnis)) {
                    if ($ds['rank'] != "Administrator" && $ds['rank'] != "Moderator") {
                        $id = $ds['rankID'];
                        if ($max[$id] == "MAX") {
                            $maximum = 2147483647;
                        } else {
                            $maximum = $max[$id];
                        }
                        safe_query("UPDATE " . PREFIX . "forum_ranks SET rank='{$rank[$id]}' WHERE rankID='{$id}'");
                        safe_query("UPDATE " . PREFIX . "forum_ranks SET postmin='{$min[$id]}' WHERE rankID='{$id}'");
                        safe_query("UPDATE " . PREFIX . "forum_ranks SET postmax='{$maximum}' WHERE rankID='{$id}'");
                    }