session_start(); include("config.php"); include("functions.php"); function path_options() { global $upload_dirs; $option = ""; foreach ($upload_dirs as $path => $pinfo) { $option .= ''; } return $option; } function check_vals() { global $err, $download_dirs; if (!isset($_POST["dir"]) || (strlen($_POST["dir"]) == 0)) { $err .= "Wybierz poziom dostępu"; return 0; } elseif (!isset($_POST["pwd"])) { $err .= "Wpisz hasło!"; return 0; } elseif ($_POST["pwd"] != $download_dirs[$_POST["dir"]]["password"]) { $err .= "Błędne hasło!"; return 0; } return 1; } $err = ""; $_SESSION["is_loggined"] = false; if (isset($_POST["login"])) { if (check_vals()) { $_SESSION["is_loggined"] = true; $_SESSION["dir"] = $_POST["dir"]; header("Location: download.php?$SLINE"); exit; } } ?>
System Wymiany Dokumentów Zespołu Szkół w Jaświach
(Wybierz poziom dostępu i wpisz hasło by wejść do Systemu).