if (!file_exists("./config.php")) { header("Location: ./install.php"); die; } include "config.php"; include "inc/mitsuba.php"; include "inc/strings/imgboard.strings.php"; if (!empty($_POST['mode'])) { $return_url = "./"; if (!empty($_POST['board'])) { $return_url = "./" . $_POST['board'] . "/"; } $conn = new mysqli($db_host, $db_username, $db_password, $db_database); $mitsuba = new Mitsuba($conn); $e = array("requestdata" => &$_POST); $mitsuba->emitEvent("imgboard.begin", $e); $mod = 0; if (!empty($_GET['mod']) && $_GET['mod'] >= 1) { if (!empty($_POST['board']) && $mitsuba->common->isBoard($_POST['board'])) { $mitsuba->admin->canBoard($_POST['board']); $mod = 1; if ($_GET['mod'] == 1) { $return_url = "mod.php?/board&b=" . $_POST['board']; } else { $mod = 2; } } else { $mod = 1; if ($_GET['mod'] == 1) { $return_url = "mod.php"; } else {