X-Git-Url: http://git.shiar.nl/minimedit.git/blobdiff_plain/c7feba44bdf1102b80a09f683321559d18755a24..b4e872adfb3c7b67447826a5b162f89590e14c80:/upload.inc.php diff --git a/upload.inc.php b/upload.inc.php index 6175fe2..e70f573 100644 --- a/upload.inc.php +++ b/upload.inc.php @@ -27,6 +27,9 @@ function userupload($input, $target = NULL, $filename = NULL) $target .= $input['name']; } + if (file_exists($target)) { + throw new Exception("bestandsnaam al aanwezig op $target"); + } if (!@move_uploaded_file($input['tmp_name'], $target)) { throw new Exception("bestand kon niet worden opgeslagen in $target"); }