Thursday, 31 July 2014

Create custom php.ini




1. You can copy php.ini  from server’s default php.ini diretory or create a new one

#cp /usr/local/lib/php.ini ./

2. Create a .htaccess file in your public_html directory and add the following contents
<IfModule mod_suphp.c>
suPHP_ConfigPath /home/<username>/public_html
<Files php.ini>
order allow,deny
deny from all
</Files>
</IfModule>

3. Create a php info page to verify

#vim info.php

<?php
phpinfo();
?>

#chown username.username info.php

No comments:

Post a Comment