up
This commit is contained in:
parent
ef8dd588a4
commit
b3c4a3fc6c
@ -1,7 +1,7 @@
|
|||||||
<?php
|
<?php
|
||||||
$target_dir = "uploads/";
|
$target_dir = "uploads/";
|
||||||
|
|
||||||
if ($_SERVER['REQUEST_METHOD'] == "POST" && isset($_POST["submit"])) {
|
if ($_SERVER['REQUEST_METHOD'] == "POST" && isset($_POST["submit"]) && $_POST["heslo"] = "davidjesuperfakt") {
|
||||||
$target_file = $target_dir . basename($_FILES["fileToUpload"]["name"]);
|
$target_file = $target_dir . basename($_FILES["fileToUpload"]["name"]);
|
||||||
$uploadOk = 1;
|
$uploadOk = 1;
|
||||||
|
|
||||||
|
@ -3,5 +3,6 @@
|
|||||||
<form action="/index.php" method="post" enctype="multipart/form-data">
|
<form action="/index.php" method="post" enctype="multipart/form-data">
|
||||||
Vyber súbor na nahratie:
|
Vyber súbor na nahratie:
|
||||||
<input type="file" name="fileToUpload" id="fileToUpload">
|
<input type="file" name="fileToUpload" id="fileToUpload">
|
||||||
|
<input type="text" name="heslo">
|
||||||
<input type="submit" value="Nahrať súbor" name="submit">
|
<input type="submit" value="Nahrať súbor" name="submit">
|
||||||
</form>
|
</form>
|
Loading…
Reference in New Issue
Block a user