Skip to Content

Apache & PHP problem

ShErbO's picture

Hi all,

I've just installed apache, it's working fine but theres one problem: PHP doesn't work. When I try to access a PHP file (phpinfo.php) through my browser, the file is simply DOWNLOADED as plain text - it's not processed.

I'm using MEPIS (all debian packages). I have installed:

apache libapache-mod-php4

My /etc/apache/modules.conf file has this line: LoadModule php4_module /usr/lib/apache/1.3/libphp4.so

/etc/apache/conf.d/php4.conf IfModule mod_php4.c> AddType application/x-httpd-php .php .phtml .php3 AddType application/x-httpd-php-source .phps /IfModule>

(I've removed the preceeding < on purpose because it's not loading correctly in the comment)

So why doesn't PHP work :S ?!!!! please help!

ShErbO's picture

Already mentioned

I already mentioned my distro. It's MEPIS.

It doesn't matter though, MEPIS is based on debian and uses the same repos.

ramez.hanna's picture

don't know about debian but i

don't know about debian but i guess you need a package for php too


the best things in life are free --- so as myself

MSameer's picture

Are you using apache or apach

Are you using apache or apache2 ?

Quote "c u next life time then when i come back as a mug of tea :P"

ShErbO's picture

Apache

MSameer: I'm using Apache1.3

libapache-mod-php4 php4

both of them are installed weird thing is.. it used to run before ! :S

p.s: mesh hateeego alex orayeb ?????

MSameer's picture

Try removing the ifmodule dir

Try removing the ifmodule directives.

Why don't you upgrade to apache2 ? adding or removing modules is as simple as a2enmod php4; /etc/init.d/apache2 force-reload

P.S Mesh hateg el bandar oraieb ? ;)

Quote "c u next life time then when i come back as a mug of tea :P"

add line in /etc/apache/httpd.conf

I have did it at my comp witch debian sarge and apache1.3 and it's wokr ok now

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.


Dr. Radut | forum