help with a php.ini file

Get help with installation and running phpBB 3.0.x here. Please do not post bug reports, feature requests, or MOD-related questions here.
Get Involved

help with a php.ini file

Postby dudenell » Thu Aug 21, 2008 6:45 am

well I guess my other topic was deleted... Im looking for help creating a custom Php.ini file... last time I tried it, all it did was kill my forum. trying to change the max upload limit to 50-100 mb and post limit to 2 gb or w/e..

lunarpages wrote:you can adjust the max file size upload with a custom php.ini file.

Because we use suPHP to parse php files, you have the option of using a custom php.ini file.

Your account can have multiple php.ini files on your account in different folders so you can customize the php processing in different folders should your script require it. A php.ini file will not inherit down into subfolders, however, you can create a .htaccess file in the same folder as the php.ini file and place the following code into it:

suPHP_ConfigPath /home/username/public_html/

where "username" is your cPanel username. This will cause the php.ini file to affect all subfolders, unless a php.ini file is in a subfolder, at which point the php.ini in the subfolder takes precedence.

In php.ini, you will need to use the actual php.ini syntax instead of the php_value or php_flag syntax you would normally use in .htaccess (Which should not be used at all):

setting_name = setting_value

So, this means if you move the settings from .htaccess to php.ini, you must convert the format. Let's say you have the following line in your .htaccess file:

php_value register_globals 0

the corresponding php.ini format is as follows:

register_globals = Off

Notice how the value 0 becomes Off and 1 becomes On. Now if your php_value has quotes like the following, for example:

php_value include_path ".:/home/user/lib"

The corresponding php.ini format is:

include_path = ".:/home/user/lib"

and so on. You should only use the settings you need to change in your php.ini.

For the PHP settings you do not have in your php.ini file, PHP will use our default configurations.


now creating this in my php file... here is what I currently have:
Code: Select all
register_globals = Off

zend_extension="/usr/local/IonCube/ioncube_loader_lin_4.4.so"
zend_extension_ts="/usr/local/IonCube/ioncube_loader_lin_4.4_ts.so"

[Zend]
zend_optimizer.optimization_level=15
zend_extension_manager.optimizer=/usr/local/Zend/lib/Optimizer-3.3.3
zend_extension_manager.optimizer_ts=/usr/local/Zend/lib/Optimizer_TS-3.3.3
zend_optimizer.version=3.3.3


zend_extension=/usr/local/Zend/lib/ZendExtensionManager.so
zend_extension_ts=/usr/local/Zend/lib/ZendExtensionManager_TS.so


and in the .httaccess file it is

Code: Select all
#
# @package phpBB3 Portal  a.k.a canverPortal  ( www.phpbb3portal.com )
# @version $Id: .htaccess,v 1.7 2008/02/09 08:18:13 angelside Exp $
# @copyright (c) Canver Software - www.canversoft.net
# @license http://opensource.org/licenses/gpl-license.php GNU Public License
#

DirectoryIndex portal.php index.php index.html index.htm

<Files "config.php">
Order Allow,Deny
Deny from All
</Files>

<Files "common.php">
Order Allow,Deny
Deny from All
</Files>
<Files 403.shtml>
order allow,deny
allow from all
</Files>


I found this:
http://drupal.org/node/97193

but it killed my site... any help?
dudenell
Registered User
 
Posts: 86
Joined: Sun Jan 27, 2008 11:24 pm

Re: help with a php.ini file

Postby Kevin Clark » Thu Aug 21, 2008 8:11 am

dudenell wrote:Im looking for help creating a custom Php.ini file

Then you need to ask on a php support site.
User avatar
Kevin Clark
Support Team Member
Support Team Member
 
Posts: 59407
Joined: Fri Jun 04, 2004 10:44 am
Location: Oxford, UK

Re: help with a php.ini file

Postby markcrobinson » Mon Nov 09, 2009 7:31 pm

It would be helpful to me if someone would post an 'optimal' pp.ini file setting for phpbb, for example, what is the ideal mempry_limit, what is the best setting for register_globals, etc.
markcrobinson
Registered User
 
Posts: 36
Joined: Sun Jul 02, 2006 11:45 pm

Re: help with a php.ini file

Postby stevemaury » Mon Nov 09, 2009 7:39 pm

As Kevin indicated, this is not a php support site. You will need to ask for php support at, say, php.net.
For REALLY good and VERY inexpensive hosting CLICK HERE

http://www.stevesstocks.com

All unsolicited PMs will be ignored.
User avatar
stevemaury
Support Team Member
Support Team Member
 
Posts: 44079
Joined: Thu Nov 02, 2006 12:21 am
Location: The U.P.
Name: Steve


Return to 3.0.x Support Forum

Who is online

Users browsing this forum: mamba, roger12, Yandex [Bot] and 36 guests