I'm not being able to upload at all, I tried to paste the sample included in the documentation and here is what came out:
Array
(
[userfile] => Array
(
[name] => tabela_multafev05.pdf
[type] =>
[tmp_name] =>
[error] => 2
[size] => 0
)
)
the file was just about 65kb in size
edit: hmm extra info: Im running this on localhost with my own Apache server, and here's the mentioned sample conde from the documentation:
<?php
// Nas versões anteriores a 4.1.0, $HTTP_POST_FILES deve ser usado ao invés de $_FILES.
// Nas versões anteriores a 4.0.3, use copy() e is_uploaded_file() ao invés move_uploaded_file
$uploaddir = '/var/www/uploads/';
$uploadfile = $uploaddir. $_FILES['userfile']['name'];
print "<pre>";
if (move_uploaded_file($_FILES['userfile']['tmp_name'], $uploaddir . $_FILES['userfile']['name'])) {
print "O arquivo é valido e foi carregado com sucesso. Aqui esta alguma informação:\n";
print_r($_FILES);
} else {
print "Possivel ataque de upload! Aqui esta alguma informação:\n";
print_r($_FILES);
}
print "</pre>";
?>