[wplug] php scripts won't run
Zach
netrek at gmail.com
Tue Feb 19 19:46:49 EST 2008
I'm having a vexing problem getting php scripts to load.
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
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.
Zac
More information about the wplug
mailing list