Изучаю php пытаюсь загрузить файл и переместить в папку вот код
<?php
$path = '../';
//mkdir($path . 'alex');
if (isset($_REQUEST['add'])) {
if ($f = action_upload_files($path) === False) {
echo "File hasn't been uploaded";
}
}
function action_upload_files($path) {
if (move_uploaded_file($_FILES['upload']['tmp_name'], $path)) {
return True;
} else {
return False;
}
}
echo '<pre>';
var_dump($_FILES['upload']);
echo '</pre>';
?>
выдает ошибки:
Warning: move_uploaded_file(): The second argument to copy() function cannot be a directory in C:\wamp64\www\project1\views\users.php on line 13
Warning: move_uploaded_file(): Unable to move 'C:\wamp64\tmp\php2286.tmp' to '../' in C:\wamp64\www\project1\views\users.php on line 13