LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Arch
User Name
Password
Arch This Forum is for the discussion of Arch Linux.

Notices


Reply
  Search this Thread
Old 08-22-2010, 09:45 AM   #1
vitorsgoncalves
Member
 
Registered: Mar 2010
Posts: 96

Rep: Reputation: 18
Apache with php


Hello

I am new to arch linux, maybe this is a stupid question:

I installed apache and php with pacman,I started the http and apache seems to be working. I can view Html pages in localhost, but php pages does not show up.

Any clues?
 
Old 08-22-2010, 09:59 AM   #2
AlucardZero
Senior Member
 
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,824

Rep: Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615Reputation: 615
No because you've given no useful debugging information. What do you mean by "does not show up"? What does show up? What error, if any, do you get from your browser? What do Apache's access_log and error_log say?
 
Old 08-22-2010, 11:16 AM   #3
vitorsgoncalves
Member
 
Registered: Mar 2010
Posts: 96

Original Poster
Rep: Reputation: 18
Quote:
Originally Posted by AlucardZero View Post
No because you've given no useful debugging information. What do you mean by "does not show up"? What does show up? What error, if any, do you get from your browser? What do Apache's access_log and error_log say?
Sorry for the bad info.

When opening php files in the browser, what shows up is the source code, not the rendered page. There is no error.

The logs are attached. (yes, my system's date is wrong)
Attached Files
File Type: txt access log.txt (5.0 KB, 9 views)
File Type: txt error log.txt (3.6 KB, 13 views)
 
Old 08-22-2010, 12:11 PM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,174
Blog Entries: 1

Rep: Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040Reputation: 2040
Hi,

You need to add in httpd.conf the following:
Code:
AddType application/x-httpd-php .php
 
Old 08-22-2010, 12:19 PM   #5
vitorsgoncalves
Member
 
Registered: Mar 2010
Posts: 96

Original Poster
Rep: Reputation: 18
Quote:
Originally Posted by bathory View Post
Hi,

You need to add in httpd.conf the following:
Code:
AddType application/x-httpd-php .php
It worked, thanks
 
Old 10-17-2010, 09:14 AM   #6
sandy6573
LQ Newbie
 
Registered: Jan 2010
Posts: 8

Rep: Reputation: 0
also add
AddType application/x-httpd-php-source .phps---for viewing source in browers for debugging purpose in http.conf file
 
  


Reply

Tags
apache, arch, php



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/shell script to install mysql,apache and php automatically stranger_6_7 Linux - General 2 08-11-2009 02:07 AM
Please help with Apache Web Server / Apache Tomcat / PHP / Java / PHP-Java Bridge jpmad4it Linux - Server 2 01-05-2009 06:07 AM
Centos 5.2 running Apache 2 and PHP 4 cannot display info.php codenjanod Linux - Server 2 08-19-2008 02:00 AM
installed php and apache yet my php pages dont load ?? jessica_lilly Linux - Software 1 11-13-2007 01:57 AM
php apache or php cgi - php learner rblampain Linux - Security 3 12-17-2004 11:10 PM

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

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