Hello,
Yes, I have installed php with yum. I used php* and just
recently was told that there is nothing to install, it is all up to date. I
did a
yum search php first, and tried to install a bunch of php modules, all of
which are already installed. I had done that a while back. I think I might
have done that from the Centos desktop and now I'm working mainly from ssh.
By not working, I mean that the index.php file does not get processed as php
- yes, I checked that the file was renamed .php and that there is no .html
file that could be run instead of the php file. So, I added to a test file
named index.php, and in the body I have a simple <?php phpinfo(); ?>
In the tutorials I found online, there is mention of the php configuration
can be in the httpd.conf file or it can be called from that file.
I have this line in the httpd.conf
Include conf.d/*.conf
Will that work? I am calling that from the file /etc/httpd/conf/httpd.conf
so it seems like a relative path would be ../conf.d/*.conf, unless this is
relative to this:
ServerRoot "/etc/httpd"
So, inside /etc/httpd/conf.d/php.conf I have
#
# PHP is an HTML-embedded scripting language which attempts to make it
# easy for developers to write dynamically generated webpages.
#
<IfModule prefork.c>
LoadModule php5_module modules/libphp5.so
</IfModule>
<IfModule worker.c>
LoadModule php5_module modules/libphp5-zts.so
</IfModule>
#
# Cause the PHP interpreter to handle files with a .php extension.
#
AddHandler php5-script .php
AddType text/html .php
#
# Add index.php to the list of files that will be served as directory
# indexes.
#
DirectoryIndex index.php
#
# Uncomment the following line to allow PHP to pretty-print .phps
# files as PHP source code:
#
AddType application/x-httpd-php-source .phps
That should be enough at least get the phpinfo(); command to run. At some
point, I got a message about there not being a php.ini file anywhere. Also,
none of the other various php modules are being called anywhere. Still, I'm
perplexed that I cannot get anything to run in terms of php. I could try
a simple echo command to test something even simpler.
Thanks,
It's great that there is such active response on this list... fast response
times when seeking help. :-)
Bruce
_______________________________________________________
Bruce Whealton - Web Design/Development/Programming
Future Wave Web Development:
http://futurewaveonline.com
Developing for the Desktop as well as for
Mobile Devices - Smartphones/Tablets
Call 919-636-5809
_______________________________________________________
-----Original Message-----
From: Reindl Harald [mailto:h.reindl at thelounge.net]
Sent: Saturday, March 09, 2013 2:17 PM
To: CentOS mailing list
Cc: Bruce Whealton
Subject: Re: [CentOS] Apache setup problems
Am 09.03.2013 20:02, schrieb Bruce Whealton:> The problem was with the SELinux. Now, though, I need to figure out
> why php is not working.
> Also, the domain fwwebdev.dnsdynamic.com is serving from
> /home/www/fwwebdev.dnsdynamic.com/ and not
> /home/www/fwwebdev.dnsdynamic.com/public_html/
>
> I guess the php module is specified in the httpd.conf file or perhaps
> in a file inside /etc/httpd/conf.d directory
specify "not working"
have you installed it at all?
i guess no