943,895 Members | Top Members by Rank

Ad:
  • PHP Discussion Thread
  • Unsolved
  • Views: 399
  • PHP RSS
May 26th, 2009
0

.htaccess files

Expand Post »
is it possible to change the max file upload and the memory limit allowed for file uploads in php with a .htaccess file.

the server my website is held on will not give me access to the php.ini file and is running php 4.4.9
Similar Threads
Reputation Points: 27
Solved Threads: 1
Posting Whiz
kevin wood is offline Offline
347 posts
since Feb 2008
May 26th, 2009
0

Re: .htaccess files

No, you cannot.
Moderator
Reputation Points: 2136
Solved Threads: 1228
Posting Genius
adatapost is offline Offline
6,527 posts
since Oct 2008
May 27th, 2009
0

Re: .htaccess files

you can. if you use the following code this will work if your server will allow you to use .htaccess files.

PHP Syntax (Toggle Plain Text)
  1. php_value post_max_size 128M
  2. php_value upload_max_filesize 128M
  3. php_value memory_limit 300M

i went about it a slightly easier way tho by putting the following code inside the php script before the image is processed

PHP Syntax (Toggle Plain Text)
  1. ini_set('memory_limit', 'xxM')
Reputation Points: 27
Solved Threads: 1
Posting Whiz
kevin wood is offline Offline
347 posts
since Feb 2008
May 27th, 2009
0

Re: .htaccess files

yes its possible using above code
Reputation Points: 16
Solved Threads: 48
Posting Whiz
BzzBee is offline Offline
327 posts
since Apr 2009

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in PHP Forum Timeline: Advance Search in PHP
Next Thread in PHP Forum Timeline: Rating in PHP





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC