Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[Solved] php5 not working with apache2
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
grooveman
Veteran
Veteran


Joined: 24 Feb 2003
Posts: 1217

PostPosted: Tue Jun 26, 2007 4:27 pm    Post subject: [Solved] php5 not working with apache2 Reply with quote

Okay... I haven't done this since apache1 and php4... Back then, I had no problems, documentation was plentiful, and everything ran as expected.

Now I am trying apache2 with php5, and according to the docs, it should be as easy as pie, but it isn't working!

I found a lot of docs, but nothing that went into detail, the best I found:

https://forums.gentoo.org/viewtopic-t-104806-highlight-php5+apache2+howto.html
and
http://gentoo-wiki.com/Apache_Modules_PHP

I emerged my apache2 and my php, as you can see:
Quote:
# emerge -pv apache

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild R ] net-www/apache-2.0.58-r2 USE="ssl -apache2 -debug -doc -ldap -mpm-itk -mpm-leader -mpm-peruser -mpm-prefork -mpm-threadpool -mpm-worker (-selinux) -static-modules -threads" 0 kB

Total: 1 package (1 reinstall), Size of downloads: 0 kB

emerge -pv php

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild R ] dev-lang/php-5.2.2-r1 USE="berkdb cli crypt gd gdbm iconv ipv6 mysql ncurses nls pcre postgres readline reflection session spell spl ssl truetype unicode xml zlib -adabas -apache2 -bcmath -birdstep -bzip2 -calendar -cdb -cgi -cjk -concurrentmodphp -ctype -curl -curlwrappers -db2 -dbase -dbmaker -debug -discard-path -doc -empress -empress-bcs -esoob -exif -fastbuild -fdftk -filter -firebird -flatfile -force-cgi-redirect -frontbase -ftp -gd-external -gmp -hash -imap -inifile -interbase -iodbc -java-external -json -kerberos -ldap -ldap-sasl -libedit -mcve -mhash -msql -mssql -mysqli -oci8 -oci8-instant-client -odbc -pcntl -pdo -pdo-external -pic -posix -qdbm -recode -sapdb -sharedext -sharedmem -simplexml -snmp -soap -sockets -solid -sqlite -suhosin -sybase -sybase-ct -sysvipc -threads -tidy -tokenizer -wddx -xmlreader -xmlrpc -xmlwriter -xpm -xsl -yaz -zip -zip-external" 0 kB

Total: 1 package (1 reinstall), Size of downloads: 0 kB


I edited /etc/conf.d/apache2 like so:
Code:

APACHE2_OPTS="-D DEFAULT_VHOST -D SSL -D SSL_DEFAULT_VHOST -D PHP5"


I restarted apache:
Code:

/etc/init.d/apache2 restart


Put this in the test file:
Code:

<?php phpinfo(); ?>


and pointed my browser to it. All I see is the uninterpreted code.

What am I missing here?

Thanks!

G
_________________
To look without without looking within is like looking without without looking at all.


Last edited by grooveman on Wed Jun 27, 2007 1:13 am; edited 2 times in total
Back to top
View user's profile Send private message
nixnut
Bodhisattva
Bodhisattva


Joined: 09 Apr 2004
Posts: 10974
Location: the dutch mountains

PostPosted: Tue Jun 26, 2007 5:20 pm    Post subject: Reply with quote

Try enabling the apache2 use flag for php
_________________
Please add [solved] to the initial post's subject line if you feel your problem is resolved. Help answer the unanswered

talk is cheap. supply exceeds demand
Back to top
View user's profile Send private message
grooveman
Veteran
Veteran


Joined: 24 Feb 2003
Posts: 1217

PostPosted: Tue Jun 26, 2007 8:47 pm    Post subject: Reply with quote

Well I'll be...

You nailed it. Sorry... there never used to be a flag like that in the old days...

Thanks for your help!
_________________
To look without without looking within is like looking without without looking at all.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum