Re: Problem: php not working with apache on RedHat 9.0

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I had same problem when installing  apache and php from rpms,so i installed from source. I installed apache2 and php from source and mysql from rpms and everything works great.

In a message dated 7/13/2004 11:56:33 AM Eastern Daylight Time, Margaret Doll <Margaret_Doll@xxxxxxxxx> writes:

>I am not able to get php working with apache on
>RedHat 9.0.  I have read through the php documentation.  I am starting
>through the apache documentation.  Any ideas as to the problem?
>
>uname -r
>2.4.20-30.9
>
>httpd -l
>Compiled in modules:
>   core.c
>   prefork.c
>   http_core.c
>   mod_so.c
>
>In /etc/httpd/conf/httpd.conf I added the next line after the loading 
>of the other modules.
>
>LoadModule php4_module modules/libphp4.so
>
>The AddType statements were already in /etc/httpd/conf/httpd/conf
>
>DirectoryIndex index.html index.htm index.shtml index.php index.php4 
>index.php3 index.cgi
><IfModule mod_php4.c>
>   AddType application/x-httpd-php .php4 .php3 .phtml .php
>   AddType application/x-httpd-php-source .phps
><IfModule mod_php3.c>
>   AddType application/x-httpd-php3 .php3
>   AddType application/x-httpd-php3-source .phps
><IfModule mod_php.c>
>   AddType application/x-httpd-php .phtml
>
>When I added the "AddModule" list as suggested in the php document 
>listed below,
>httpd wouldn't start.
>
>"Apache 1.3 configuration directives found
>  please read /usr/share/doc/httpd-2.0.40/migration.html"
>
>I tried to view two test.php files
>
>more mad.php
><html>
><head></head>
><body>
><?php
>$myvar = "Hello World";
>         echo( $myvar);
>?>
></body>
></html>
>
>I get a blank screen on this file.
>
>   and
>more test.php
><?php phpinfo(); ?>
>
>I get a screen with "<?php phpinfo(); ?>" typed
>exactly on it.
>
>rpm -aq | grep httpd
>httpd-2.0.40-21.9
>redhat-config-httpd-1.0.1-18
>httpd-manual-2.0.40-21.9
>[root@chemps Software]# rpm -aq | grep php
>php-imap-4.2.2-17.2
>php-4.2.2-17.2
>php-ldap-4.2.2-17.2
>php-pgsql-4.2.2-17.2
>php-mysql-4.2.2-17.2
>
>
>-rwxr-xr-x    1 apache   apache         93 Jul 13 10:45 mad.php
>
>from  us2.php.net/manual
>
>4.  Unix: I installed PHP using RPMS, but Apache isn't processing the 
>PHP pages! What's going on here?
>
>Assuming you installed both Apache and PHP from RPM packages,        
>you need to uncomment or add some or all of the following lines       
>in your httpd.conf file:
>
># Extra Modules
>AddModule mod_php.c
>AddModule mod_php3.c
>AddModule mod_perl.c
>
># Extra Modules
>LoadModule php_module         modules/mod_php.so
>LoadModule php3_module        modules/libphp3.so     # for PHP 3
>LoadModule php4_module        modules/libphp4.so     # for PHP 4
>LoadModule perl_module        modules/libperl.so
>And add:
>
>AddType application/x-httpd-php3 .php3    # for PHP 3
>AddType application/x-httpd-php .php      # for PHP 4
>... to the global properties, or to the properties of the        
>VirtualDomain you want to have PHP support added to.
>
>7. Unix/Windows: I have installed PHP, but when I try to       access a 
>PHP script file via my browser, I get a blank screen.
>
>Do a 'view source' in the web browser and you will probably       find 
>that you can see the source code of your PHP script.       This means 
>that the web server did not send the script to       PHP for 
>interpretation. Something is wrong with the server       configuration 
>- double check the server configuration against       the PHP 
>installation instructions.
>-- 
>redhat-list mailing list
>unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe
>https://www.redhat.com/mailman/listinfo/redhat-list
>


-- 
redhat-list mailing list
unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list

[Index of Archives]     [CentOS]     [Kernel Development]     [PAM]     [Fedora Users]     [Red Hat Development]     [Big List of Linux Books]     [Linux Admin]     [Gimp]     [Asterisk PBX]     [Yosemite News]     [Red Hat Crash Utility]


  Powered by Linux