here is the code i am using
<?php
$numoffile = 2;
$file_dir = "/home/datad967/public_html/fs/ <+ here is where i want to echo the directory name+>";
if ($_POST) {
for ($i=0;$i<$numoffile;$i++) {
if (trim($_FILES['myfiles']['name'][$i])!="") {
$newfile = $file_dir.$_FILES['myfiles']['name'][$i];
move_uploaded_file($_FILES['myfiles']['tmp_name'][$i], $newfile);
$j++;
}
}
}
if (isset($j)&&$j>0) print "Your file(s) has been uploaded.<br>";
print "<form method='post' enctype='multipart/form-data'>";
for($i=0;$i<$numoffile;$i++) {
print "<input type='file' name='myfiles[]' size='20'><br>";
}
print "<input type='submit' name='action' value='Upload'>";
print "</form>";
?>
its used for when a user creates a folder the upload will be place in there and in order toupload it needs the path to there folder, so i figured instead of changing it i would echo the folder name that the script is in.