Site Suggestions Post site suggestions and comments

HALP Server spitting out PHP, not encoding it as HTML before pushing to client

Thread Tools
 
Search this Thread
 
Old September-27th-2007 | 10:09 AM
  #1  
_Kansei_'s Avatar
Thread Starter
Tech/How-To/Northeast Mod
 
Joined: Feb 2006
Posts: 2,517
From: Rochester, New York
_Kansei_ is on a distinguished road
HALP Server spitting out PHP, not encoding it as HTML before pushing to client

Somethin is up with the PHP setup on the server, as the situation in the subject line keeps happening.

Different browsers, different operating systems, different computers, all the same symptom. Firefox won't just display PHP code, so it spits it out as a file download. This happens when I click basically anything on the site, including sometimes submitting a new post or thread. --but obviously it doesn't happen all the time.
Old September-27th-2007 | 10:51 AM
  #2  
_Kansei_'s Avatar
Thread Starter
Tech/How-To/Northeast Mod
 
Joined: Feb 2006
Posts: 2,517
From: Rochester, New York
_Kansei_ is on a distinguished road
It took four tries just to get back to this thread lol

see attached screenshot. It took over 50 clicks (I stopped counting) to get the photo attached.

If no one else here is a PHP programmer, could someone let me see the output of phpinfo(); so I can do some diagnostics myself?
Attached Thumbnails HALP Server spitting out PHP, not encoding it as HTML before pushing to client-php.jpg  
Old September-27th-2007 | 11:17 AM
  #3  
KrayzieFox's Avatar
Spam Czar!!
 
Joined: Aug 2004
Posts: 2,315
From: Cedar Falls, Iowa
KrayzieFox is on a distinguished road
Dude I dunno what's going on with you but I'm not having any problems at all.
Old September-27th-2007 | 02:18 PM
  #4  
sumo_Bob's Avatar
Registered User
 
Joined: Mar 2007
Posts: 378
From: Birmingham, AL
sumo_Bob is on a distinguished road
happens on occasion, to many php based pages, dunno what causes it.... Try hitting CRTL + F5, and see if that solves it.
Old September-27th-2007 | 03:20 PM
  #5  
jsusanka's Avatar
Registered User
 
Joined: Aug 2007
Posts: 66
jsusanka is on a distinguished road
that is usually a misconfiguration with the web server - doesn't know how to handle files with the php extension. it is either that or php extensions to the web server are not installed.

this is site is running apache on linux so make sure you have the following line in your config file for apache

DirectoryIndex index.php

also make sure the config file is loading php module. the modules should be a directory of of /etc/ called apache2/mod* or /etc/httpd/mod*

anyway hope this helps.
Old October-2nd-2007 | 05:00 PM
  #6  
IB ATEST's Avatar
Administrator
 
Joined: Jul 2007
Posts: 16
IB ATEST is on a distinguished road
Apache was crashing on one of the two web servers due to a problem with one of the modules. As the process would die, the connection would close. The crash apparently happened early enough in the connection process that Apache was not able to send content type headers to the browser. (Usually the server will say, "This is an HTML file" in a way that the browser understands.) Because it didn't get that header info, it would revert to its internal handler, which is very simple - it looks up the extension (in this case .php) to figure out what program to open it with.

You don't actually get sent the PHP source code, but it looks like you do because your browser is offering to open the content (in this case a zero-length file) for you in a text editor.

In any case, it should be fixed now.
Related Topics
Thread
Thread Starter
Forum
Replies
Last Post
Cone420
Mazda3/Mazdaspeed3
3
January-14th-2009 08:08 PM
chiefmg
Off-Topic
1
October-11th-2007 09:46 AM
misbehave
3rd Gen Protege/MazdaSpeed/P5/MP3
2
September-3rd-2003 01:32 AM
pr0tege5
3rd Gen Protege/MazdaSpeed/P5/MP3
18
May-4th-2002 08:53 PM
mazdaspeedwest
Site Suggestions
5
October-19th-2001 12:26 PM

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 



All times are GMT -5. The time now is 10:40 PM.