LinuxQuestions.org
Review your favorite Linux distribution.
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 09-17-2005, 01:57 AM   #1
mjl3434
Member
 
Registered: Sep 2003
Location: Los Angeles, CA
Distribution: Fedora 8
Posts: 100

Rep: Reputation: 15
configuring apache, php


I'm running slackware, and want to get apache and php to work together. The final goal is to get phpBB2 working. As of now Apache works and will host regular html files. However when I attempt to open a .php file that the Apache is serving it just shows the php source as text.

My best guess is that php and apache aren't properly configured to work together. The only thing I came across is that when manually doing the whole ./configure, make, make install process that one needs to show apache where php is and php where apache is. Since this was installed as a binary (I believe it comes off the cd as a binary) I can't exactly just reinstall.

Any ideas of what causes this, and how to fix it?

As always any help is greatly appreciated.
 
Old 09-17-2005, 02:25 AM   #2
Nylex
LQ Addict
 
Registered: Jul 2003
Location: London, UK
Distribution: Slackware
Posts: 7,464

Rep: Reputation: Disabled
In your /etc/apache folder, do you have a file called mod_php.conf? If so, open up your /etc/apache/httpd.conf file and add

Include /etc/apache/mod_php.conf

to it and restart your server (my Include line is right at the bottom of httpd.conf). Does that help?
 
Old 09-17-2005, 11:35 AM   #3
mjl3434
Member
 
Registered: Sep 2003
Location: Los Angeles, CA
Distribution: Fedora 8
Posts: 100

Original Poster
Rep: Reputation: 15
The php_conf file exists, and so does that Include line, which I uncommented. Unfortunatly this does not solve the problem, the php source still shows up as text.
 
Old 09-20-2005, 01:13 AM   #4
mjl3434
Member
 
Registered: Sep 2003
Location: Los Angeles, CA
Distribution: Fedora 8
Posts: 100

Original Poster
Rep: Reputation: 15
Since I'm still having the problem of php source showing up as text...

Does anybody know how I can determine which piece of software is causing the problem? i.e. How can I know that it is PHP is causing the problem and not Apache, or vice versa?

Man pages, README's, searching the forum, all seems to be getting nowhere, I just need a good clue of where to start. Would it be helpful to just uninstall each package and then install from source? Since they're allready installed, and Apache is working I think that's just as likely to cause new problems as to fix old ones. Because of this I'm reluctant to do it. I'd rather figure out why it isn't working.

Last edited by mjl3434; 09-20-2005 at 01:20 AM.
 
Old 09-22-2005, 07:49 PM   #5
student04
Member
 
Registered: Jan 2004
Location: Georgia
Distribution: OS X, CentOS
Posts: 669

Rep: Reputation: 34
I'm using tinysofa and have php4 and mysql4 installed. I have the same problem, that the source is displayed and not the actual page. I do not have an /etc/apache directory, and do not have a 'php_conf' file.

I'm trying to get 'bytehoard' to work, and it uses mysql and php4 (not 5).

How do you get apache to use the php stuff... i don't know much about webservices

thanks

*EDIT** oops... i'm sorry, i forgot to restart apache. It works now! Didn't the thread closely enough.

Last edited by student04; 09-22-2005 at 07:59 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
configuring php for apache PennyroyalFrog Linux - Newbie 3 02-08-2008 12:58 AM
Configuring PHP with Apache. LinuxStart Linux - Software 6 07-11-2005 10:15 AM
Configuring Apache, PHP AND mySql Stryks Linux - Newbie 2 10-14-2004 03:02 AM
Configuring php on apache Dakkar Linux - Software 5 06-01-2004 10:26 AM
Configuring Apache and PHP... causticmtl Slackware 2 07-06-2003 02:11 PM


All times are GMT -5. The time now is 08:38 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration