Web Hosting Forum | Lunarpages


*
Welcome, Guest. Please login or register.
Did you miss your activation email?



Login with username, password and session length
February 09, 2012, 11:33:26 AM

Pages: [1]   Go Down
  Print  
Author Topic: php.ini  (Read 1530 times)
desmondlewissmith
Newbie
*
Offline Offline

Posts: 2


« on: April 25, 2008, 12:00:10 PM »

This should be an easy one...  My website tells me:

Your server does not allow file uploads larger than 2 MB.
Please contact your hosting company and request that the php setting 'upload_max_filesize' is increased to at least 5 MB

I was told to modify the .htaccess file with the following text:

php_value upload_max_filesize 5m

but when I do, it brings my site down.

If I add a php.ini file with the line:

upload_max_filesize 5m

it doesn't do anything...

Any advice would be GREATLY appreciated
Logged
Mitch
Berserker Poster
*****
Offline Offline

Posts: 12838


WWW
« Reply #1 on: April 25, 2008, 12:06:56 PM »

This can be done with the php.ini file. Here is how you do it

Create a file under public_html and name it php.ini ( if you do not have one yet. )  Put the following in it

upload_max_filesize = 5M
post_max_size = 5M

Replace the 5 with whatever size you want. If you are letting other people
upload, a size cap protects your storage space from abuse/overuse.

You will then need to add this line to a .htaccess file:
(Please replace "yourusername" with your cpanel user name an add to the end of the comand line the folder(s) to the location of the php.ini file - Also there is a space between path and /home)

suPHP_ConfigPath /home/Yourusername/public_html
Logged

New to Web Site Hosting? Check Out the Lunarpages Blog Hosting Guide!


Follow us @lunarpages on Twitter!
Important Threads: Read This Before Posting! | Lunarforums Rules! | Mitch's Link of the Day!
Also, be sure to check out and subscribe to the Lunartics Blog and the Lunarpages Newsletter !

Need Web Hosting Help? Check out the Lunarpages Web Hosting Wiki. It has tons of tips, tutorials and resources!
Lord High Warlock
Intergalactic Cowboy
*****
Offline Offline

Posts: 55


I am The Lord thy Warlock.


WWW
« Reply #2 on: August 03, 2009, 05:41:36 PM »

Mitch: I just wanted to say THANK YOU for this reply!  I found this when I did a search for "PHP.INI" and it answered my all my questions.

Thank you! Grinning Grinning
Logged


Mitch
Berserker Poster
*****
Offline Offline

Posts: 12838


WWW
« Reply #3 on: August 04, 2009, 01:07:53 PM »

Mitch: I just wanted to say THANK YOU for this reply!  I found this when I did a search for "PHP.INI" and it answered my all my questions.

Thank you! Grinning Grinning

You are more than welcome!
Logged

New to Web Site Hosting? Check Out the Lunarpages Blog Hosting Guide!


Follow us @lunarpages on Twitter!
Important Threads: Read This Before Posting! | Lunarforums Rules! | Mitch's Link of the Day!
Also, be sure to check out and subscribe to the Lunartics Blog and the Lunarpages Newsletter !

Need Web Hosting Help? Check out the Lunarpages Web Hosting Wiki. It has tons of tips, tutorials and resources!
mochimad
Newbie
*
Offline Offline

Posts: 1


« Reply #4 on: March 04, 2010, 01:19:41 PM »

This did not work for me at all.

Is that code shown EXACTLY as it should be put into the .INI file and the htaccess file? Where in the htaccess file? Before or after the # END WordPress line?
Logged
MichaelT
Support
Jabba the Hutt
*****
Offline Offline

Posts: 523



« Reply #5 on: March 05, 2010, 01:59:22 AM »

This did not work for me at all.

Is that code shown EXACTLY as it should be put into the .INI file and the htaccess file? Where in the htaccess file? Before or after the # END WordPress line?

The suPHP_ConfigPath /home/Yourusername/public_html line can go before that or after, should not matter as long as its on its own line. Also make sure your replace Yourusername with your account username.
Logged

--

Support and Assistance:
Contacting Us
Hosting Plans
Affiliate Program
Wiki and Tutorials
Pages: [1]   Go Up
  Print  
 
Jump to: