[nycphp-talk] Uploading file with PHP
Tom
tom at supertom.com
Sun Nov 21 10:28:38 EST 2004
Hi Joseph,
These are all possible options from php.ini that can effect upload. I
downloaded xampp myself and took them from their php.ini, so doubt you are
having a problem with these, but just putting them in for a sanity check:
memory_limit = 8M
upload_max_filesize = 2M
post_max_size = 8M
file_uploads = On
;upload_tmp_dir = (make sure this is writeable by the User the web server is
running as)
max_execution_time = 30
Now, pertaining to the LimitRequestBody Directive:
I have Apache 2x on Redhat 9, and I have a /etc/httpd/conf/conf.d directory,
and inside of there I have a php.conf file. In that file I have this:
<Files *.php>
SetOutputFilter PHP
SetInputFilter PHP
LimitRequestBody 524288
</Files>
I know for certain that if you don't adjust the limitrequestbody attribute,
you won't be able to upload files larger than this number.
On this page:
http://us2.php.net/features.file-upload
A fellow mentions adding this to his *httpd.conf* file. Make sure to adjust
the number to be larger than your upload. You'll need to make a block like
this for every extension you want PHP to handle, so if you are having PHP
process .html files, you'll need one that says Files *.html.
Also see here:
http://forums.invisionpower.com/lofiversion/index.php/t115421.html
If it is not this, I'm out of ideas.
Good Luck!
Tom
Long Island PHP Users Group
http://www.liphp.org
-----Original Message-----
From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org] On
Behalf Of Joseph Crawford
Sent: Friday, November 19, 2004 5:45 PM
To: NYPHP Talk
Subject: Re: [nycphp-talk] Uploading file with PHP
i am using xampp and in my /opt/lampp/etc/ i do not see a php.conf, i am
checking httpd.conf for the value you requested and i do not see anything
pertaining to that.
--
Joseph Crawford Jr.
Codebowl Solutions
codebowl at gmail.com
For a GMail account
contact me OFF-LIST
_______________________________________________
New York PHP Talk
Supporting AMP Technology (Apache/MySQL/PHP)
http://lists.nyphp.org/mailman/listinfo/talk
http://www.newyorkphp.org
More information about the talk
mailing list