RE: [PHP] Attachments
| From: | Jason Soza | Date: | Sun, 21 Apr 2002 18:33:26 +0000 |
| Subject: | RE: [PHP] Attachments | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-93900@lists.php.net to get a copy of this message | ||
Hmm... Okay, I used this script I found on hotscripts - it copies the entire
file to the specified directory:
echo "<p><center>Trying to upload to: "
. $upload_path . $filename . "</center></p>\n";
if ( file_exists($upload_path.$filename) ) {
echo "<p><font color='red'><center>"
. $message["fileexists"]."</font></center></p>";
} else {
if( move_uploaded_file($HTTP_POST_FILES['userfile']['tmp_name'],
$upload_path.$filename) ) {
echo "<p><center>" .
$message["complete"]."</center></p>";
} else {
echo "<p><font color='red'><center>"
.
$message["incomplete"]."</font></center></p>";
}
Now why would this work but the e-mail scripts not?
-----Original Message-----
From: Jason Wong [mailto:php-general@gremlins.com.hk]
Sent: Sunday, April 21, 2002 10:13 AM
To: php-general@lists.php.net
Subject: Re: [PHP] Attachments
On Monday 22 April 2002 01:51, Jason Soza wrote:
> I haven't been able to identify what process actually truncates the file.
This should be the easiest to nail down. Add a bit of code so that when the
file gets uploaded, it gets copied somewhere, then you can manually check
its
size. Obviously, if the filesize is OK then the problem is further down the
line (probably the mail code).
--
Jason Wong -> Gremlins Associates -> www.gremlins.com.hk
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
/*
f u cn rd ths, itn tyg h myxbl cd.
*/
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php