Answer the question
In order to leave comments, you need to log in
CentOS: how to make PHP and Apache friends and what is this php-apache package?
Vagrant, CentOS 6, PHP7
When requested, gave out a php-file with text.
changed short_open_tag to On in php.ini - did not help.
Changed in httpd.conf
<FilesMatch "^\.ht">
Require all denied
</FilesMatch>
<FilesMatch \.php$>
SetHandler application/x-httpd-php
</FilesMatch>
LoadModule php7_module modules/libphp7.so
. And so he did. When trying to restart, Apache swears at this very line - it says that it cannot find the /etc/httpd/modules/libphp7.so
. Further googling gave such information that in some cases it helps to install a certain "php-apache" package. I got the impression that this is some kind of mythical package, because I couldn’t google information about it, yum install couldn’t set it on it, and I didn’t find anything similar in the repositories. I looked for mod_php in turnips, tried to install mod_php70u.x86_64 from the found ones - it did not help. What to do?? SetHandler application/x-httpd-php
, и заработало. Я так и не понял, в чем было дело.
Answer the question
In order to leave comments, you need to log in
look here for centos 7 but still. and in general I advise you to switch to centos 7
On CentOS6 you can install php70-php-7.0.33-23.el6.remi.x86_64.rpm
https://centos.pkgs.org/6/remi-x86_64/php70-php-7....
if the turnips are still alive.
This RPM package contains mod_php - the Apache web server (httpd) module, by downloading which Apache will be able to process php scripts on its own
This package contains the module (often referred to as mod_php)
which adds support for the PHP language to system Apache HTTP Server.
php70-mod_php
/opt/remi/php70/root/usr/lib64/httpd/modules/libphp7.so
there will be a php library (module) for apache /usr/lib64/httpd/modules/libphp70.so
- a link to it nginx
php-fpm
mod_php instead
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question