Shhh
Новичок
Не могу сделать upload на сервер
Обрабатываю принятый файл, как описано в мануале:
print "<pre>";
if (move_uploaded_file($_FILES['userfile']['tmp_name'], $path )) {
print "File is valid, and was successfully uploaded. ";
print "Here's some more debugging info:\n";
print_r($_FILES);
} else {
print "Possible file upload attack! Here's some debugging info:\n";
print_r($_FILES);
}
print "</pre>";
===========
А получаю:
Possible file upload attack! Here's some debugging info:
Array
(
[userfile] => Array
(
[name] => discover-platinum-credit-card.gif
[type] => image/gif
[tmp_name] => d:\temp\php1454.tmp
[error] => 0
[size] => 1988
)
)
Вроде же все правильно?

Обрабатываю принятый файл, как описано в мануале:
print "<pre>";
if (move_uploaded_file($_FILES['userfile']['tmp_name'], $path )) {
print "File is valid, and was successfully uploaded. ";
print "Here's some more debugging info:\n";
print_r($_FILES);
} else {
print "Possible file upload attack! Here's some debugging info:\n";
print_r($_FILES);
}
print "</pre>";
===========
А получаю:
Possible file upload attack! Here's some debugging info:
Array
(
[userfile] => Array
(
[name] => discover-platinum-credit-card.gif
[type] => image/gif
[tmp_name] => d:\temp\php1454.tmp
[error] => 0
[size] => 1988
)
)
Вроде же все правильно?
