Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

CGI Error In Perl Script

Status
Not open for further replies.

TTMTech

Programmer
Feb 5, 2003
29
US
HI !

I am new to perl programming. Our web application was working fine and suddenly I got error as follow :

CGI Error

The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are:


Is anyone help me how to solve this problem ?
 
The script is trying to print to the screen before sending the HTTP header. Typically this line of code is not present, commented out so it is non functional or the program flow is altered such that something else prints to the screen before this line->
print "Content-type: text/html \n\n\r\r";
 
I think what Haunter meant was
[tt]print "Content-type: text/html \r\n\r\n";[/tt]
Haunter's version will work on UNIX-like systems, but on others, it would fail. //Daniel
 
Well, "\015\012" is the internet standard (according to the various protocols' RFCs, but "\n" should be just fine, and has always worked well for me.
Code:
print "Content-type: text/html\n\n";
Sincerely,

Tom Anderson
Order amid Chaos, Inc.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top