×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Apache, php4, FreeBSD

How do I install Apache and php4 on FreeBSD? by Wishdiak
Posted: 6 May 05

Installing Apache and php4 on FreeBSD (5.x) is relatively painless, if you use the FreeBSD ports system. After logging in as root:

1. Install Apache (1.3 in this example) from FreeBSD ports.
#cd /usr/ports/www/apache13
#make install clean

2. Add Apache to rc.conf so that it starts at boot.
#echo 'apache_enable="YES"' > /etc/rc.conf

3. Install php4 and extensions from FreeBSD ports.
#cd /usr/ports/www/mod_php4
#make install clean
#cd /usr/ports/lang/php4-extensions
#make install distclean

4. Check to see that Apache is configured for php4.
#cd /usr/local/etc/apache
#more httpd.conf

The following lines in httpd.conf should be UNcommented:
  LoadModule php4_module     libexec/apache/libphp4.so
  AddModule mod_php4.c
  <IfModule mod_dir.c>
     DirectoryIndex index.php index.html index.htm
  </IfModule>

5. Restart Apache.
#apachectl restart

Back to Linux (server) FAQ Index
Back to Linux (server) Forum

My Archive

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close