How to avoid a custom php extension be overwritten?

mapg

Member
Dec 9, 2004
7
0
151
Hi all,

I got a custom php extension added in ...

/usr/local/apache/conf/php.conf

And everytime I use EasyApache, this extension is overwritten and added the common php extensions but not mine certainly.

I would like to retouch the template of this (or anything) to avoid this overwritting.

Is it possible?

Note: I do not want to add a custom extension in the mime-types of Cpanel because I do not want to have .htaccess in the main user folder.

Thank you very much in advance.

Mapg
 

Zishan

Well-Known Member
Aug 6, 2005
107
1
168
/usr/local/apache/conf/php.conf has a note at top stating:

This file was automatically generated by the Cpanel PHP Configuration system.

Manual edits of this file will be lost when Apache is updated.
Which extension you are adding ? You may also look at Custom Configure it may help you.
 

mapg

Member
Dec 9, 2004
7
0
151
Thank you for your reply.

I solved the problem adding in ...

Main >> Service Configuration >> Apache Configuration >> Pre VirtualHost Include

The following ...

AddType application/x-httpd-php .my_custom_php_extension

And other one for Perl as follow ...

AddHandler cgi-script .my_custom_perl_extension

Thank for your help

Mapg