LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 07-08-2007, 10:17 PM   #1
methodtwo
Member
 
Registered: May 2007
Posts: 146

Rep: Reputation: 18
apachce+php not working on gentoo?


i'm a noob using gentoo and today i emerged apache with apache2 in my USE variable in /etc/make.conf, started the server and tested it from a browser using: http://localhost/ .So far so good.
Then i emerged dev-lang/php and the apache config file got
updated to include: APACHE_OPTS="-D DEFAULT_HOST -D PHP5.
I then created a sample .php file in /var/www/localhost/htdocs/ .But when i try to access this file from a browser using: http:///var/www/localhost/htdocs/file.php OR: file:///var/www/localhost/htdocs/file.php
i just get error 404: filenot found OR the url was not found on the server.Does this mean PHP is not working as an apache module?, if so what can i do?.Or does it just mean
that the server needs more info on where to find it's filesystem?, if so how do i give this info to apache?
Thankx kindly for any help

Last edited by methodtwo; 07-08-2007 at 10:19 PM.
 
Old 07-09-2007, 02:08 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
Error 404 means that the file you asked for does not exist. Mind that you have to request a php page like this:
http://localhost/file.php (assuming that /var/www/localhost/htdocs is your DocumentRoot) so your apache server can parse the php code and show you the output.

Regards
 
  


Reply



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
PHP Recompile Question (Gentoo, USE flag) justanothersteve Linux - Software 4 06-04-2008 02:53 PM
LXer: Gentoo Linux PHP Security Advisory LXer Syndicated Linux News 0 05-27-2007 09:46 PM
PHP installation with zlib on gentoo emanresu Linux - Software 1 07-11-2006 02:03 AM
installing php gentoo jrtayloriv Linux - Software 3 01-22-2005 06:16 AM
PHP not producing output - Apache2 on Gentoo cadsterza Linux - Software 2 09-06-2004 06:18 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 11:58 AM.

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