LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 03-03-2003, 10:47 AM   #1
thomas050682
LQ Newbie
 
Registered: Feb 2003
Distribution: Debian, SuSE
Posts: 6

Rep: Reputation: 0
Apache & PHP & Mysql


Hi!

first i've installed mysql on my debian 3.0 server.
that works.
now i installed apache 1.3.26 and php3.

how can i configure apache with php?

when i try to open the index.php file in a client-browser, i get a request on saving or opening the file, but the browser don't open the file.

the message looks something like this:

--------------------------------------------------------
you have chosen to download a file of type: application/x-httpd-php from
http://servername/foobar/

what should mozilla do with this file?
+open using ...
+save to disk
-----------------------------------------------------------


thanks a lot in advance,

tom


Last edited by thomas050682; 03-03-2003 at 10:49 AM.
 
Old 03-03-2003, 11:10 AM   #2
Crashed_Again
Senior Member
 
Registered: Dec 2002
Location: Atlantic City, NJ
Distribution: Ubuntu & Arch
Posts: 3,503

Rep: Reputation: 57
Did you isntall apache from source? If so you have to compile PHP support into it. Do:

./configure --help

to see what the php option is. If its something like --enable-php then you would do:

./configure --enable-php
 
Old 03-03-2003, 11:39 AM   #3
thomas050682
LQ Newbie
 
Registered: Feb 2003
Distribution: Debian, SuSE
Posts: 6

Original Poster
Rep: Reputation: 0
i installed apache with

apt-get install apache

from the debian package.

./configure don't work here.
thank you for any suggestion.

tom
 
Old 03-03-2003, 11:45 AM   #4
Crashed_Again
Senior Member
 
Registered: Dec 2002
Location: Atlantic City, NJ
Distribution: Ubuntu & Arch
Posts: 3,503

Rep: Reputation: 57
Maybe you don't have the php modules in your httpd.conf file.
 
Old 03-03-2003, 12:32 PM   #5
SlickWilly
Member
 
Registered: Dec 2002
Posts: 327

Rep: Reputation: 30
Could be a number of things. Those pointed out below are good options, you also might not have .php configured as a page that can be served by apache, and so it thinks it's a download (Ie. I don't know what to do with this page).

That would be a missing 'add-handler' option.

To be honest, there are *so* many things that could have gone wrong here you're best off just running down the list of 'what you need to do' when compiling / configuring the above applications.

A quick search on Freshmeat (http://www.freshmeat.net) for 'apache php mysql' reveals this page which is awesomely helpful

http://freshmeat.net/projects/apache.../?topic_id=905

Slick.
 
Old 03-03-2003, 04:21 PM   #6
jkrohn
Member
 
Registered: Jan 2003
Location: Urbana, IL
Distribution: Slackware, Mandrake
Posts: 62

Rep: Reputation: 15
There are a few things you will want to check.

In your httpd.conf file, do you have and types defined?
ie
Code:
 AddType application/x-httpd-php .php
Including the mod_php.conf?
Code:
Include /etc/apache/mod_php.conf
Is mod_php.conf setup correctly?

Unfortunately this is just one of many, many ways to setup apache to use PHP as SlickWilly pointed out.
 
  


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
Slackware guide for AMP Apache MySQL & PHP xushi Slackware 35 05-11-2006 12:18 PM
Apache ADVX & PHP w/ MySQL MonServeur Linux - Software 3 11-21-2004 04:11 PM
Apache ADVX & PHP w/ MySQL MonServeur Mandriva 2 11-21-2004 02:39 PM
From RedHat9 to FreeBSD (Apache 2 & Mysql & PHP 4) guardian653 *BSD 5 12-11-2003 06:31 PM
Apache & Php & MySql te_conway Linux - Software 2 12-21-2001 05:06 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 08:39 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