Initial commit 2
This commit is contained in:
parent
8c6a83f3be
commit
7c1ac022cb
28 changed files with 8640 additions and 0 deletions
16
upload.php
Normal file
16
upload.php
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
<?php
|
||||
$ds = DIRECTORY_SEPARATOR; //1
|
||||
|
||||
$storeFolder = 'uploads'; //2
|
||||
|
||||
if (!empty($_FILES)) {
|
||||
|
||||
$tempFile = $_FILES['file']['tmp_name']; //3
|
||||
|
||||
$targetPath = dirname(__FILE__) . $ds . $storeFolder . $ds; //4
|
||||
|
||||
$targetFile = $targetPath . $_FILES['file']['name']; //5
|
||||
|
||||
move_uploaded_file($tempFile, $targetFile); //6
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue