. //////////////////////////////////////////////////////////////////////////////// // Last modified 05/aug/2012 by cassio@ime.usp.br require 'header.php'; if(($ct = DBContestInfo($_SESSION["usertable"]["contestnumber"])) == null) ForceLoad("../index.php"); if(($st = DBSiteInfo($_SESSION["usertable"]["contestnumber"],$_SESSION["usertable"]["usersitenumber"])) == null) ForceLoad("../index.php"); if (isset($_GET["delete"]) && is_numeric($_GET["delete"])) { DBBkpDelete($_GET["delete"],$_SESSION["usertable"]["usersitenumber"],$_SESSION["usertable"]["contestnumber"], $_SESSION["usertable"]["usernumber"]); ForceLoad("files.php"); } if (isset($_FILES["sourcefile"]) && isset($_POST["Submit"]) && $_FILES["sourcefile"]["name"]!="") { if ($_POST["confirmation"] == "confirm") { $type=myhtmlspecialchars($_FILES["sourcefile"]["type"]); $size=myhtmlspecialchars($_FILES["sourcefile"]["size"]); $name=myhtmlspecialchars($_FILES["sourcefile"]["name"]); $temp=myhtmlspecialchars($_FILES["sourcefile"]["tmp_name"]); if ($size > $ct["contestmaxfilesize"]) { LOGLevel("User {$_SESSION["usertable"]["username"]} tried to submit file " . "$name with $size bytes ({$ct["contestmaxfilesize"]} max allowed).", 1); MSGError("File size exceeds the limit allowed."); ForceLoad("run.php"); } if (!is_uploaded_file($temp) || strlen($name)>100) { IntrusionNotify("file upload problem."); ForceLoad("../index.php"); } DBNewBkp ($_SESSION["usertable"]["contestnumber"], $_SESSION["usertable"]["usersitenumber"], $_SESSION["usertable"]["usernumber"], $name, $temp, $size); } ForceLoad("files.php"); } ?>
\n"; echo " \n"; echo " \n"; echo "\n"; echo " \n"; } echo "
Bkp # Time File
" . $run[$i]["number"] . "" . dateconvsimple($run[$i]["timestamp"]) . ""; echo $run[$i]["filename"] . ""; echo "
"; if (count($run) == 0) echo "
NO BACKUPS AVAILABLE
"; ?>

To erase a file, click on its number. To download a file, click on its name. To submit a new backup file, just fill in the following fields:
File (size restrictions apply):