I've tried a few more things, still with no success. Increasing post_max_size and upload_max_filesize to 1000000M doesn't fix the problem. Turning error logging on doesn't seem to catch any errors. Is it possible that this is a problem with apache, and if so how should I go about fixing it?

Thanks,
Grant

Grant Rutherford wrote:

Hi there,

I'm trying to get a file upload to work with PHP.

The file I'm attempting to upload is a 742kB pdf file, but this will have to work for files up to 50Mb of all types eventually.

The following test pages work fine if the receiving page (testdone) is saved with an html extension, but they return a "Document Contains no Data" error if it has a php extension. The inclusion or exclusion of a "MAX_FILE_SIZE" hidden field does not seem to effect the situation.

In addition, the upload appears to work fine for smaller files. (239kB works fine on both .php and .html)

I'm using PHP with apache viewed on Mozilla, and the following simple HTML:

teststart.html:
<HTML><HEAD><TITLE>Test Page</TITLE></HEAD>
<BODY>
<H1 ALIGN=CENTER>Test Page</H1>
<FORM ACTION='testdone.***' METHOD=POST NAME=aform ENCTYPE='multipart/form-data'>
<P ALIGN=CENTER><INPUT TYPE=FILE NAME=testfile><INPUT TYPE=SUBMIT NAME=add VALUE='Submit'></P>
</FORM>
</BODY>
</HTML>


testdone.***:
<HTML><HEAD><TITLE>Test Page</TITLE></HEAD>
<BODY>
<H1 ALIGN=CENTER>Test Page</H1>
<P ALIGN=CENTER>File Upload Successful</P>
</BODY>
</HTML>


The parts of my php.ini file that I think may be relevant are:


memory_limit = 80M
post_max_size = 10000M
file_uploads = On
upload_max_filesize = 10000M

Any help would be appreciated

Thanks,
Grant






--
Grant Rutherford
Iders Incorporated
600A Clifton Street
Winnipeg, MB
R3G 2X6
http://www.iders.ca
tel: 204-779-5400 ext 36
fax: 204-779-5444
================================
Iders Incorporated: Confidential
================================
Note: This message is intended solely for the use of the designated
recipient(s) and their appointed delegates, and may contain
confidential information.  Any unauthorized disclosure, copying or
distribution of its contents is strictly prohibited.  If you have
received this message in error, please destroy it and advise the sender
immediately by phone, Email or facsimile.

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to