if (isset($_FILES['file'])) {
if ($_FILES['file']['error'] != 0) {
switch ($_FILES['file']['error'])
{
case 1:
print 'The file is to big.'; // php installation max file size error
exit;
break;
case 2:
print 'The file is to big.'; // form max file size error
exit;
break;
case 3:
print 'Only part of the file was uploaded';
exit;
break;
case 4:
print 'No file was uploaded';
exit;
break;
case 6:
print "Missing a temporary folder.";
exit;
break;
case 7:
print "Failed to write file to disk";
exit;
break;
case 8:
print "File upload stopped by extension";
exit;
break;
}
} else {
//
}
}
Title:
Get upload file error
Description:
if (isset($_FILES['file'])) { if ($_FILES['file']['error'] != 0) { switch ($_FILES['file']['erro...
...
Rating:
4