Re: httpd not interpreting a php file
| From: | Tim Streater | Date: | Sat, 25 Oct 2014 07:01:00 +0000 |
| Subject: | Re: httpd not interpreting a php file | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-324005@lists.php.net to get a copy of this message | ||
On 25 Oct 2014 at 07:34, Gergely Buday <gbuday@gmail.com> wrote:
>>> I did tests and my Apache does interpret simple php files.
>>>
>>> I copied a directory structure from a working web server and my
>>> login.php is not interpreted. Apache emits some source code from the
>>> file.
>>
>> Did you copy httpd.conf?
>
> I use the default httpd.conf as provided on centos 7 httpd installation,
> modulo
>
> ProxyPassMatch ^/(.*\.php(/.*)?)$ fcgi://127.0.0.1:9000/var/www/html/$1
> DirectoryIndex /index.php
>
> What do you mean by copying? From what place to where?
Well you said you copied a directory structure. So I assume you are making a new installation,
meaning you need to copy the httpd.conf file too.
1) As asked by francis, does your httpd.conf file have a statement like: AddType
application/x-httpd-php .php
2) Does your httpd.conf file have a statement like: LoadModule php5_module
/usr/libexec/apache2/libphp5.so (with the appropriate path)
3) Why do you not tell us your operating system and version of apache?
--
Cheers -- Tim