Bluehost.com Web Hosting $6.95

Apache and php

This is a discussion on Apache and php within the Apache Web Server forums, part of the Web Server and Related Forums category; I have just innstalled Mandrake 9.1, Apache2 and php 4.3.0. I have added a line in httpd....


Go Back   Usenet Forums > Web Server and Related Forums > Apache Web Server

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 08-24-2003
Jan V.Pedersen
 
Posts: n/a
Default Apache and php

I have just innstalled Mandrake 9.1, Apache2 and php 4.3.0. I have added a
line in httpd.conf - "AddType application/x-hhtpd-php .php3". The line is
in the end of the config-file.

Would this be enough to get php to work? I can't read php-files, and I am
not sure where to put the files either. The Apache root dir is
var/www/html. Is that the right place to put the php3-files?

--
mvh Jan Vidar
www.janvidar.com
  #2 (permalink)  
Old 08-24-2003
PaZ
 
Posts: n/a
Default Re: Apache and php

Try:


A quick edit of a couple of Apache config files is all that' s needed to
alert Apache to PHP. First, open up /etc/httpd/conf/httpd.conf and add the
following lines

LoadModule php3_module libexex/libphp3.so

AddModule mod_php3.c

Make sure to check the LoadModule and AddModule sections of the conf file to
make sure these lines aren' t already there -- doubles are bad. Next, edit
the /etc/httpd/conf/srm.conf and add the following lines

AddType application/x-httpd-php3 .php3

AddType application/x-httpd-php3-source .phps

to tell Apache to use PHP on any file with a .php3 extension.

Last up -- restart Apache and you should be good to go

/etc/rc.d/init.d/httpd restart





ScriptAlias /php/ "h:/php/"
AddType application/x-httpd-php .php3
Action application/x-httpd-php "/php/php.exe"


"Jan V.Pedersen" <janvidar_remThis_@start.no> wrote in message
news:ZKR1b.16494$os2.230792@news2.e.nsc.no...
> I have just innstalled Mandrake 9.1, Apache2 and php 4.3.0. I have added a
> line in httpd.conf - "AddType application/x-hhtpd-php .php3". The line is
> in the end of the config-file.
>
> Would this be enough to get php to work? I can't read php-files, and I am
> not sure where to put the files either. The Apache root dir is
> var/www/html. Is that the right place to put the php3-files?
>
> --
> mvh Jan Vidar
> www.janvidar.com



  #3 (permalink)  
Old 08-24-2003
Jan V.Pedersen
 
Posts: n/a
Default Re: Apache and php

PaZ wrote:

> Try:
>
>
> A quick edit of a couple of Apache config files is all that' s needed to
> alert Apache to PHP. First, open up /etc/httpd/conf/httpd.conf and add the
> following lines
>
> LoadModule php3_module libexex/libphp3.so
>
> AddModule mod_php3.c
>
> Make sure to check the LoadModule and AddModule sections of the conf file
> to make sure these lines aren' t already there -- doubles are bad. Next,
> edit the /etc/httpd/conf/srm.conf and add the following lines
>
> AddType application/x-httpd-php3 .php3
>
> AddType application/x-httpd-php3-source .phps
>
> to tell Apache to use PHP on any file with a .php3 extension.
>
> Last up -- restart Apache and you should be good to go
>
> /etc/rc.d/init.d/httpd restart



Thanks! :)

I have 2 problems now: There are 2 conf.files: http2.conf and httpd.conf. In
the file httpd.conf these lines are already there, but not in the
http2.conf.

The other problem: I can't seem to find srm.conf file anywhere. SHould I
make one? How?

Thx in advance :)

- Jan Vidar

  #4 (permalink)  
Old 08-26-2003
Gaming-Forums.net
 
Posts: n/a
Default Re: Apache and php

This page will tell you all you need to know
http://www.php.net/manual/en/install.apache2.php


On Sun, 24 Aug 2003 00:18:38 +0200, "Jan V.Pedersen"
<janvidar_remThis_@start.no> wrote:

>I have just innstalled Mandrake 9.1, Apache2 and php 4.3.0. I have added a
>line in httpd.conf - "AddType application/x-hhtpd-php .php3". The line is
>in the end of the config-file.
>
>Would this be enough to get php to work? I can't read php-files, and I am
>not sure where to put the files either. The Apache root dir is
>var/www/html. Is that the right place to put the php3-files?


 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT +1. The time now is 07:19 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0