please help, im getting error
Warning: Unable to open 'Array' for reading: No such file or directory in /home/pcplay/public_html/scbmx/uploader.php on line 19
for this code:
whats going wrong?
<head>
<script language="JavaScript">
<!--
function MM_jumpMenu(targ,selObj,restore){
eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
if (restore) selObj.selectedIndex=0;
}
//-->
</script>
</head>
<?php
if(($REQUEST_METHOD == 'POST')){
?>
shit<br>
<table cellspacing="0" border="1" bordercolor="999999">
<?php
foreach($HTTP_POST_FILES['fileup'] AS $value) {
if($value != ""){
if(copy($value, "$directory/$filename")){
echo "<tr><td>File $filename was Uploaded sucsessfully</td></tr>";
}else{
echo "<tr><td>File $filename failed to upload</td></tr>";
}
}
}
?>
</table>
<?php
}else{
?>
<form method="post" action="?doupload&directory=./bmx/<?php echo $dir; ?>" ENCTYPE="multipart/form-data">
<table cellspacing="0" border="1" bordercolor="999999">
<tr>
<td colspan="2">
Number of Files to uplaod:
<select name="n" onChange="MM_jumpMenu('self',this,0)">
<?php
$nam = 0;
while($nam < 20){
$nam++;
echo "<option value=\"?n=$nam&dir=$directory\" ";
if($n == $nam){
echo " selected";
}
echo ">$nam</option>";
}
?>
</select>
</td>
</tr>
<br>
<?
if(!isset($n)){
$n = 1;
}
while($num < $n){
$num++;
echo "<tr><td>File $num : </td><td><input type=\"file\" name=\"fileup[]\" value=\"\"></td></tr>";
}
?>
</table>
<center><input type="submit" value="upload"></center>
</form>
<?php
}
?>