LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-24-2005, 10:49 AM   #1
ProTrooper
LQ Newbie
 
Registered: Aug 2005
Posts: 9

Rep: Reputation: 0
Enable PHP


Hello, I installed PHP5 and Apache along with ISPConfig on a web server. While testing it local, I put a PHP script in the default directory (/var/www/html). The page just brought up the code. The PHP worked when I set them up through ISPConfig. How do I enable the PHP in the default directory?
 
Old 08-24-2005, 04:26 PM   #2
bulliver
Senior Member
 
Registered: Nov 2002
Location: British Columbia, Canada
Distribution: Gentoo x86_64; FreeBSD; OS X
Posts: 3,764
Blog Entries: 4

Rep: Reputation: 78
You need to set up apache to send *.php files to the interpreter. How to do this varies wildly depending on your distro, but generally you need to add at least:

Code:
LoadModule php4_module    apache2-extramodules/libphp4.so
and:
Code:
AddType application/x-httpd-php .php
to the appropriate sections of httpd.conf. The examples I gave are for php4, but php5 should be similar. I suggest you use the php guide to help you with the specifics:
http://www.php.net/manual/en/install.unix.apache2.php

Last edited by bulliver; 08-24-2005 at 04:30 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Enable XML in PHP admstng Linux - Software 2 01-25-2005 07:57 AM
Slackware 8: How do I enable PHP? dimmu Linux - Software 1 11-15-2004 01:00 PM
PHP Issue: --enable pcntl nemesisza Linux - Software 3 10-21-2004 09:24 AM
Enable session on PHP 4.4.3 robertoneto123 Linux - Newbie 1 04-13-2004 02:45 PM
How to enable php in Apache2 under RHlinux 8? Luc Linux - Newbie 3 12-14-2002 08:41 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:20 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration