diff --git a/public/fun.php b/public/fun.php index 4c9a4aa6..8c246477 100644 --- a/public/fun.php +++ b/public/fun.php @@ -3,6 +3,7 @@ require_once("../include/bittorrent.php"); dbconn(); require_once(get_langfile_path()); require_once(get_langfile_path("",true)); +loggedinorreturn(); $action=$_GET["action"]; if (!$action) { diff --git a/public/modrules.php b/public/modrules.php index 60f303dc..02421ea2 100644 --- a/public/modrules.php +++ b/public/modrules.php @@ -38,7 +38,7 @@ elseif (isset($_GET["act"]) && $_GET["act"]=="addsect"){ header("Refresh: 0; url=modrules.php"); } elseif (isset($_GET["act"]) && $_GET["act"] == "edit"){ - $id = $_GET["id"]; + $id = intval($_GET["id"]); $res = @mysql_fetch_array(@sql_query("select * from rules where id='$id'")); stdhead("Edit rules"); //print(""); diff --git a/public/takestaffmess.php b/public/takestaffmess.php index d987b85a..2cb2ad69 100644 --- a/public/takestaffmess.php +++ b/public/takestaffmess.php @@ -15,7 +15,8 @@ if (!$msg) stderr("Error","Don't leave any fields blank."); $updateset = $_POST['clases']; if (is_array($updateset)) { - foreach ($updateset as $class) { + foreach ($updateset as &$class) { + $class=intval($class); if (!is_valid_id($class) && $class != 0) stderr("Error","Invalid Class"); }