Justtechjobs.com Find a programming school near you






Online Campus Both


php3-list | 199807

[PHP3] Upload problem From: Philippe Locatelli (Philippe.Locatelli <email protected>)
Date: 07/15/98

Hello dear php3 user,

I try to use the upload fonctionality with php3.
I use an apache 1.2.6 web server with php3 compiled as module.
When I try to upload a file the error message given by the apache web
server in error-log is:
------------------------------------
[Wed Jul 15 09:25:33 1998] copy script args timed out for 194.209.2.252
[Wed Jul 15 09:25:33 1998] Possible PHP3 memory leak detected
(harmless): 339 bytes from functions/post.c:84
------------------------------------

Can somebody help me?
Thank you very much for your responses

Philippe Locatelli

here the source code of the html file:
------------------------------------
<html>
<head></head>
<body>

<FORM ENCTYPE="multipart/form-data" ACTION="upload.phtml" METHOD=POST>
<INPUT TYPE="hidden" name="MAX_FILE_SIZE" value="1000000000">
        <INPUT NAME="picFile" TYPE="file">
        <INPUT TYPE="submit" VALUE="Send file">
</FORM>
</body></html>
-------------------------------------

and the source of the php3 file:
----------------------------------------
<html>
<head></head>
<body>

<?
        if($picFile == "none") {
                phpExit();
        }

        if(filesize($picFile) > $MAX_FILE_SIZE ) {
                echo "File too big<br>" ;
                unlink($picFile);
                phpExit();
        }

        copy($picFile, "../pics/$type/$picFile_name");
        unlink($picFile);
?>
</body></html>
-------------------------------------

--
 -----------------------
| Philippe Locatelli    |
| IT architecture and   |
|    new technologies   |
| Phone: +41 61 2801529 |
 -----------------------

-- PHP 3 Mailing List http://www.php.net/ To unsubscribe send an empty message to php3-unsubscribe <email protected> To subscribe to the digest list: php3-digest-subscribe <email protected> For help: php3-help <email protected> Archive: http://www.tryc.on.ca/php3.html