Currently moving a site to a new server, here is the info from CPanel:
The server I used before allowed me to modify the php settings, by the use of the "php_flag" commands, however when I tried them on this new server, an error message:Operating system Linux
Kernel version 2.6.16.29-11774_1
Apache version 2.0.63
PERL version 5.8.8
PHP version 5.2.5
MySQL version 5.0.45-community
cPanel Build 11.18.3-RELEASE 21703
cPanel Pro 1.0 (RC1)
The php settings that I have needed to change in the past are these from .htaccess:/home/username/public_html/.htaccess: Invalid command 'php_flag', perhaps mis-spelled or defined by a module not included in the server configuration
plus forcing any php errors to a file outside of the web root (and no php errors to the browser of course). I don't think the new server uses phpsuexec , but instead: Mod SuPHP, UniqueId, Userdir, and maybe Fileprotect.Code:php_flag session.use_trans_sid off php_flag register_globals off php_flag allow_url_fopen off
The settings from "EasyApache" are as follows:
Now for some questions please.Apache 2.0.63
Access
Actions
Alias
AuthnDefault
AuthzHost
Autoindex
DIR
Expires
Fileprotect
Prevent Users from reading other webroots
Frontpage
Headers
Log Config
Mime
Negotiation
Mod SuPHP
This option will make the following changes to your profile prior to the build:
Enables:
CGI (PHP v4)
CGI (PHP v5)
Proxy
Setenvif
Status
UniqueId
Userdir
Mod Security
v1.9.5 for Apache 1.3, v2.1.4 for Apache 2.x This option will make the following changes to your profile prior to the build:
Enables:
UniqueId
Mod Bandwidth
v2.1 for Apache 1.3, v0.8 for Apache 2.x - see documentation that can found by clicking "More Info" for details
Zend Optimizer for PHP
3.3.3 - please read documentation that can found by clicking "More Info" to fully understand this option
PHP 5.2.5
Bcmath
Calendar
Curl
CurlSSL
FTP
GD
Imap
Magic Quotes
Mbstring
Mcrypt
Mhash
Mysql
compile mysql support against php bundled libraries (if the system mysql is checked it takes precedence of this option)
Mysql of the system
compile mysql (and mysqli if its checked) support against the system libraries
MySQL "Improved" extension.
MySQLi does not replace the standard MySQL extension. Requires MySQL 4.1 or later. !! mysqli may not work on all systems, contact your support provider for mysqli support !!
Openssl
Pspell
Sockets
TTF (FreeType)
XSL
XmlRPC
Zlib
Requires that zlib is installed and up to date
1. Is there any method that I can use, to place the "php_flag" commands into .htaccess ?
2. Is modifying php.ini the ONLY method to modify the php settings ?
I have tried a small php.ini to override one php setting, as a test, it worked okay, however my understanding of using php.ini is .........
(i) I will need a complete copy of the current php.ini , and then modify that
(ii) The file php.ini then needs to be in every sub-path as well, at least every sub-path that has an include statement.
There must be an easy way to do this, after all, don't they call it "EasyApache" ?![]()



LinkBack URL
About LinkBacks
Reply With Quote





