LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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-30-2005, 02:52 PM   #1
SpiderIRE
Member
 
Registered: Jan 2005
Distribution: FC (Planet CCRMA Kernel)
Posts: 81

Rep: Reputation: 15
Apache2 and PHP5


I need some help! installed Apache with no problems and can start it just fine! installed PHP with the standard ./configure, make, make install (and i'm pretty sure it installed alright)!

I am running Fedora Core 3 and placed a PHP test file into the directory /usr/local/apache2/htdocs/ the code is fine, but when i go to that file in a web browser and try to execute it, instead of running the file through PHP it simple displays the code from the phptest.php file in the browser!

i've read some places that i have to edit the httpd.conf file to point to the PHP parser or something......???? i need help so any ideas??

Thanks in advance!
-David
 
Old 09-30-2005, 02:56 PM   #2
Mega Man X
Guru
 
Registered: Apr 2003
Location: ~
Distribution: Ubuntu, FreeBSD, Solaris, DSL
Posts: 5,339

Rep: Reputation: 63
If you are 100% sure the php-code is not flawed (would not hurt posting it here though ), I would advice you to look at your apache.conf or http.conf (it could be at /etc/apache/ or /etc/httpd.conf... if you are not sure which file it is, try searching for it with find. Might take a while, but I'd start at etc if I was you.e.g: find /etc -name apache.conf).

Once you've found that file, search for "DirectoryIndex" and make sure to place index.php in the front of the other extensions.

Regards!
 
Old 09-30-2005, 03:04 PM   #3
SpiderIRE
Member
 
Registered: Jan 2005
Distribution: FC (Planet CCRMA Kernel)
Posts: 81

Original Poster
Rep: Reputation: 15
alrighty the code:

<html>
<head>
<title> blah, blah </title>
</head>
<body>
<?php phpinfo(); ?>
</body>
</html>

simple! and as for those files-didn't find them! there isn't even a directory in /etc called apache........??? any more ideas??

Thanks,
David

EDIT:found the httpd.conf file in /usr/local/apache2/conf/
and also, where would PHP install by default?

Last edited by SpiderIRE; 09-30-2005 at 03:21 PM.
 
Old 09-30-2005, 04:25 PM   #4
SpiderIRE
Member
 
Registered: Jan 2005
Distribution: FC (Planet CCRMA Kernel)
Posts: 81

Original Poster
Rep: Reputation: 15
so i did some searching around and it turns out i don't have this libphp*.so file! anyone wanna guess why not?? seriously though-i need help fast with this thing!

for both Apache and PHP all i did was:

tar zxvf filename.tar
./configure
make
make install

and it didn't throw up an error of any kind! apache will start fine, but it won't recognise PHP and i don't have the libphp*.so file! that's basically an update to everything!!

Thanks!!
 
  


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
SLES9/apache2 and PHP5 scabrous1 Suse/Novell 1 12-15-2005 06:14 AM
Apache2 and PHP5 rul3r Slackware 7 09-11-2005 06:21 PM
Apache2 + PHP5.0.3 24jedi *BSD 1 07-21-2005 04:07 PM
Installing Apache2 and PHP5 biglaz Linux - General 1 10-15-2004 11:42 PM
Apache2 with PHP5 on Fedora C2 cdrobsonjr Linux - Software 5 09-13-2004 06:06 PM


All times are GMT -5. The time now is 07:30 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration