LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mandriva
User Name
Password
Mandriva This Forum is for the discussion of Mandriva (Mandrake) Linux.

Notices


Reply
  Search this Thread
Old 10-07-2006, 02:28 PM   #1
sandWorm
LQ Newbie
 
Registered: Jul 2006
Posts: 11

Rep: Reputation: 0
Thumbs up Apache php postgres headaches


The main problem is all the guides I can find on the net are not Mandriva specific.

I Installed Mandriva (Free 2006 edition) and chose the apache
php and postgres packages.

There is a web serve running, at least I get a page when I go to http://localhost an html doc with "It works" on it. But I have no idea if it is apache or another default installed server.

Does anyone know where Mandriva hides the /apache/htdocs folder this is where I believe I need to put an index.php with
the code
PHP Code:
<?php
        phpinfo
()
       
?>
I have read that I need to set up an account for postgres but I'll tackle later when I at least know php and apache are running.

Any help welcome and sorry if this is a bit scatty my head is spinning from trawling the mandriva files system

Thanks

Last edited by sandWorm; 10-07-2006 at 02:31 PM.
 
Old 10-07-2006, 08:38 PM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,700

Rep: Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895Reputation: 5895
The default is /var/www/html. The setting is DocumentRoot in the /etc/httpd/conf/httpd.conf file.
Apache would be the default webserver and if postgresql was selected when you installed Mandriva then the postgres user should already be created.
 
Old 10-08-2006, 02:09 PM   #3
sandWorm
LQ Newbie
 
Registered: Jul 2006
Posts: 11

Original Poster
Rep: Reputation: 0
thanks for the help
 
Old 10-09-2006, 10:51 AM   #4
sandWorm
LQ Newbie
 
Registered: Jul 2006
Posts: 11

Original Poster
Rep: Reputation: 0
Having found httpd.conf php refuses to work

Wasn't sure whether to re post here or start a new thread, also there is a similar thread (same problems) over at software/server

My httpd.conf had no mention of php anywhere so I have added

LoadModule php5_module /usr/lib/apache-extramodules/mod_php5.so

and

AddType application/x-httpd-php .php .phtml .html
AddType application/x-httpd-php-source .phps



I also have added index.php to list under the heading

<ifModule mod_dir.c>
DirectoryIndex
</IfModule>

as that was suggested in a tutorial

I have also tried using

<IfModule mod_php5.so>
AddType application/x-httpd-php .php .phtml .html
AddType application/x-httpd-php-source .phps
</IfModule>

AND

AddType application/x-httpd-php5 .php .phtml .html
AddType application/x-httpd-php5-source .phps

Nothing seems to work, I have been stopping and restarting Apache after each change. The furthest I have got was firefox asking what I wanted index.php opened with, but I can't remember which version of the httpd.conf I had for that.

There seem to be a lot tutorials out there none of those I have followed result in working php. Most of them go from not having Apache/Php installed so I wonder if this is my problem. I have a fresh install of Mandriva 2006 and selected the Apache and php packages.

Any help very welcome. Thanks
 
  


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
Apache PHP Postgres works but not together... PeO Linux - Software 1 10-12-2005 08:01 AM
unable to connect to postgres from php jkmartha Linux - Software 1 07-04-2005 02:51 AM
php postgres connecting needed help vickr1z Linux - Newbie 2 11-11-2004 03:13 AM
php postgres problem Xing Linux - Software 3 03-08-2004 12:22 PM
Apache and Flash Headaches Kong Linux - Software 2 01-02-2004 01:54 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Mandriva

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