user directory from a form
| From: | Neil Jackson | Date: | Sun, 01 Oct 2006 15:45:03 +0000 |
| Subject: | user directory from a form | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-42444@lists.php.net to get a copy of this message | ||
I apologise for using this mailing list but I cannot find another.
I have a form
echo "<FORM ACTION='$PHP_SELF' METHOD='POST'>";
echo "<CENTER><TABLE BGCOLOR='yellowgreen' BORDERCOLOR='green' CELLSPACING='0' WIDTH='90%' BORDER='1'><TR>";
echo "<TD ALIGN='center'><FONT FACE='Arial' SIZE=5><b>News Letter</b></FONT></TD>";
echo "</TR></TABLE>";
echo "<TABLE BORDER='0' CELLSPACING='0' CELLPADDING='1'>";
echo "<TR>";
echo "<TD>Subject</TD>";
echo "<TD><INPUT TYPE='text' NAME='subject' WIDTH='50'></TD>";
echo "</TR>";
echo "<TR>";
echo "<TD>File name (Any attachment)</TD>";
echo "<TD><INPUT TYPE='file' NAME='filename' WIDTH='50'></TD>";
echo "</TR>";
I pass this to another file. I am trying to read the directory that the users file is in. ie "/srv/www/htdocs/functions/email/file.txt", I want to read the "/srv/www/htdocs/functions/email/". The variable $filename only gives the "file.txt" as a value.
--
Neil Jackson DipPharm DipData
Tel: +27 31 7632795
Fax: +27 31 7632960