[Chugalug] LAMP problem

Garrett Gaston garrett85 at hotmail.com
Fri Mar 1 01:23:33 UTC 2013


I ran telnet localhost 80 in one terminal and GET in another, here is what I got.

garrett at mint-desktop ~ $ GET /var/www/phptest.php HTTP/1.0
<?php

phpinfo()

?>

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US" lang="en-US">
<head>
<title>Topic Related Searching at HTTP.COM.</title>
<meta  name="description" content="Hypertext Transfer Protocol - Topic Related Searching (TRS)" />
<meta  name="keywords" content="http, hypertext, hypertext transfer protocol, topic related searching, trs, http.com, sponsored search results" />
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<frameset rows="*,0" frameborder="NO" border="0" framespacing="0">
  <frame name="mainFrame" src="http://domains.googlesyndication.com/apps/domainpark/domainpark.cgi?cid=ca-dp-og03&s=HTTP.com&kw=network%2Cnetwork+monitoring&kw_type=broad">
</frameset>
<noframes>
<body bgcolor="#FFFFFF">
Please visit <a href="http://domains.googlesyndication.com/apps/domainpark/domainpark.cgi?cid=ca-dp-og03&s=HTTP.com&kw=network%2Cnetwork+monitoring&kw_type=broad">this link</a> since your browser does not support frames.
</body>
</noframes>
</html>

> From: kigtest at hotmail.com
> Date: Thu, 28 Feb 2013 19:41:57 -0500
> To: chugalug at chugalug.org
> Subject: Re: [Chugalug] LAMP problem
> 
> You can also check the mime-type by telnetting to port 80.
> From the command line:
> 
> telnet localhost 80
> GET /somefile.php HTTP/1.0
> Host: localhost 
> 
> (Two returns there)
> 
> It should show you the mime-type in the headers.  Text/html is good.  Application/octet-stream not so much
> 
> Keith
> 
> On Feb 28, 2013, at 7:15 PM, "Mike Harrison" <cluon at geeklabs.com> wrote:
> 
> >> My opening tag <?php and closing tag ?> are present. This problem is occurring with my html & PHP files as well as files that
> >> I'M copying from else ware just to make sure. So the syntax should be good. The PHP files are working just as long as I point
> >> the URL straight to the file, 'localhost/somefile.php' but their downloading instead of executing when trigged from an html
> >> form.
> > 
> > While not the real problem, part if it the mime types for your files are wrong. In Apache, set your default mime document type to text/html
> > 
> > You can also do this in your PHP code.. or server mime types comfig.. or.. or..
> > 
> > 
> > _______________________________________________
> > Chugalug mailing list
> > Chugalug at chugalug.org
> > http://chugalug.org/cgi-bin/mailman/listinfo/chugalug
> _______________________________________________
> Chugalug mailing list
> Chugalug at chugalug.org
> http://chugalug.org/cgi-bin/mailman/listinfo/chugalug
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://chugalug.org/pipermail/chugalug/attachments/20130228/f9148e6f/attachment.html>


More information about the Chugalug mailing list