LinuxQuestions.org
Visit Jeremy's Blog.
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 03-09-2009, 07:59 AM   #1
adrianc.grigoras
LQ Newbie
 
Registered: Dec 2008
Posts: 14

Rep: Reputation: 0
Php files don't load in my Apache Server


Hi,

I try to configure Apache to load Php. Everything works for Php4, but I upgrade to Php5.

I compile Php5 with apxs2 path, and it configures me the file:

Code:
LoadModule php4_module        /usr/lib/apache2/libphp4.so
LoadModule php5_module        /usr/lib/apache2/libphp5.so

AddType application/x-httpd-php .php .phtml
AddType application/x-httpd-php-source .phps
When I try to load html files, it works.

When I hit in the console: php -f /path/to/file , it works.

But no php files are load in .Apache

I also restart it.
 
Old 03-09-2009, 08:37 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
You cannot run add php support in apache for both php4 and php5 using modules. One of the phps must be run as a cgi. There are lots of howtos about the required configuration. Here is one written for Debian based distros.
 
Old 03-09-2009, 10:38 AM   #3
adrianc.grigoras
LQ Newbie
 
Registered: Dec 2008
Posts: 14

Original Poster
Rep: Reputation: 0
Hi Bathory,

I comment this:
#LoadModule php4_module /usr/lib/apache2/libphp4.so

It works. I believe that Php5 add support for php4 in this way.

Thank you very much!
 
  


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
Gentoo Linux - how to map Apache server to look at php files in multiple locations bg108 Linux - Newbie 3 02-07-2008 04:51 AM
installed php and apache yet my php pages dont load ?? jessica_lilly Linux - Software 1 11-13-2007 01:57 AM
PHP & Apache - php files not processing aolong Linux - General 1 12-17-2006 03:09 AM
Server load code Apache+PHP mindfrost82 Linux - Software 1 01-03-2005 10:43 AM
Can't load php module in Apache pepino Linux - Newbie 2 10-21-2003 10:26 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

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