Zach wrote:
2008/2/19, Sergio <[EMAIL PROTECTED]>:
Hello,
do you have a line like this in your config files:
AddType application/x-httpd-php .php .phtml .php3
I think it is in the file: /etc/apache2/mods-enabled/php5.conf
That should do the trick.
Hello Sergio,
Yes everything seems fine yet it still doesn't work - very perplexing.
Here is what I know so far:
When I try to load one locally such as /var/www/phpsysinfo/index.php
it opens a dialog box asking me whether I'd like to download it or
open with an editor, it never renders the PHP script. I also tried
remotely by loading http://www.club.cc.cmu.edu/~chaos/foo.php in my
browser and it just prints out the file contents.
I verified that apache2 has the php module loaded:
netrek:~# a2enmod php5
This module is already enabled!
I also confirmed that in /etc/apache2/mods-available/dir.conf
DirectoryIndex has an entry for index.php:
<IfModule mod_dir.c>
DirectoryIndex index.html index.cgi index.pl index.php index.xhtml ind
ex.htm
</IfModule>
And I also confirmed that in /etc/apache2/mods-available/php5.conf it
has as apropriate AddType entry:
<IfModule mod_php5.c>
AddType application/x-httpd-php .php .phtml .php3
AddType application/x-httpd-php-source .phps
</IfModule
Also I confirmed /etc/apache2/mods-enabled/php5.conf has:
<IfModule mod_php5.c>
AddType application/x-httpd-php .php .phtml .php3
AddType application/x-httpd-php-source .phps
</IfModule>
And /etc/apache2/mods-enabled/dir.conf has:
<IfModule mod_dir.c>
DirectoryIndex index.html index.cgi index.pl index.php index.xhtml ind
ex.htm
</IfModule>
Here are the packages I have installed:
ii libapache2-mod-php5 5.2.4-2+b1
server-side, HTML-embedded scripting languag
ii php5 5.2.4-2
server-side, HTML-embedded scripting languag
ii php5-cgi 5.2.4-2+b1
server-side, HTML-embedded scripting languag
ii php5-cli 5.2.4-2+b1
command-line interpreter for the php5 script
ii php5-common 5.2.4-2+b1
Common files for packages built from the php
ii apache2 2.2.6-3
Next generation, scalable, extendable web se
ii apache2-common 2.0.55-4
next generation, scalable, extendable web se
ii apache2-mpm-prefork 2.2.6-3
Traditional model for Apache HTTPD
ii apache2-utils 2.2.6-3
utility programs for webservers
ii apache2.2-common 2.2.6-3
Next generation, scalable, extendable web se
ii iceweasel 2.0.0.11-1
lightweight web browser based on Mozilla
Must I change /etc/apache2/apache2.conf somehow to get this working?
Running Debian lenny. So apache is passing the php files as if they
were just normal text files or something. They are never passed off to
the php module and executed for some reason. Any help would be greatly
appreciated. As far as I can tell it *should* work but doesn't
obviously.
Regards,
Zach
What does 'apache2ctl -M' tell you? That should tell you what modules
apache is loading. Have you restarted apache?
Thx
jeff
--
8 out of 10 Owners who Expressed a Preference said Their Cats Preferred
Techno.
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]