1)Create a script php5-cgi in /home/username/public_html/cgi-bin with permission 755 and owership username. Add the entries
" #!/bin/sh
exec /usr/local/cpanel/cgi-sys/php5 -c /home/username/public_html/php.ini "
2)Create a .htaccess in the directory you need custom php5 configuration working with the following code in it.
Options All -Indexes
AddHandler php5 .php
Action php5 /cgi-bin/php5.cgi
3) Copy the php.ini file that is currently used( php -i | grep php.ini ) to /home/username/public_html and change according to your needs.
If any error occurs , please check ScriptAlias is set for cgi-bin folder or try changing the Handler name or add AddType.
No comments:
Post a Comment