-
uploads empty?
I have this form and when submitted it is suppose to echo out the $_FILES variable, but that is empty. the POST variables look fine and register_globals are OFF and file uploads are ON. the file being uploaded is only 2k so the size is not a factor. something has changed on the server but I have no clue as to what. funny though this script works just fine on another server with globals ON. php version is 4.3.1 on both.
has anybody ran into something like this before?
PHP Code:
<html>
<head>
</head>
<body>
<?php
if ($_GET['action'] == "save"){
print_r($_FILES);
} else {
echo"<form action=\"upload.php?action=save\" method=\"post\" ENCTYPE=\"multipart/form-data\" name=\"NewProd\" id=\"Form2\" onSubmit=\"return new_product(this)\">\n";
echo"<table border=\"0\" cellspacing=\"3\" cellpadding=\"0\" width=\"100%\">\n";
echo" <tr>\n";
echo" <td bgcolor=\"".CELLCOLOR."\"><span style=\"font-face:Verdana; font-size:12px;\"><b>Product Name: </b></span> <input type=\"text\" name=\"prodname\" value=\"\"></td>\n";
echo" </tr>\n";
echo" <tr>\n";
echo" <td valign=\"top\" bgcolor=\"".CELLCOLOR."\"><p><span style=\"font-face:Verdana; font-size:12px;\"><b>Zipped File:</b></span><br />\n";
echo" <br /><input type=\"file\" name=\"zipped\" /></td>\n";
echo" </tr>\n";
echo"</table>\n";
echo"<input type=\"hidden\" name=\"MAX_FILE_SIZE\" value=\"5000000\">\n";
echo"<input type=\"submit\" name=\"new\" value=\"Save New Product\">\n";
echo"</form>\n";
}
?>
</body>
</html>