Click here to get back home

Premature Ending of script headers

 HomeNewsGroups | Search | About
 comp.lang.perl.modules    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
Premature Ending of script headers Autumn-Fox 08-17-2005
Posted by Autumn-Fox on August 17, 2005, 4:53 pm
Please log in for more thread options


I think you guys may be tired of this question.But I don't really know
how to solve it.

#!/usr/bin/perl
print "Context-type: text/html\n\n";
print "Hello EveryOne";

--------------------------------------
Even this sample doesn't work. The perl directory is right.
I typed in vi, so I don't think there are any extra characters.
The output under the command window is good.
Anyone has ideas about this question?



Posted by Gunnar Hjalmarsson on August 18, 2005, 2:19 am
Please log in for more thread options


Autumn-Fox wrote:
> I think you guys may be tired of this question.

Correct.

> But I don't really know how to solve it.
>
> #!/usr/bin/perl
> print "Context-type: text/html\n\n";
> print "Hello EveryOne";
>
> --------------------------------------
> Even this sample doesn't work.

Try content-type.
^

--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl


Posted by Autumn-Fox on August 17, 2005, 8:50 pm
Please log in for more thread options


it's a mistype.All my .cgi files couldn't run on this machine, which I
can run on another one.
I have two versions apache on my machine. If I start 1.3 version, I can
run all the cgi files.
If I start 2.2 version, I can't .I really don't know what's wrong with
all my cgi files.
Maybe it's a configuration problem.

I



Posted by Gunnar Hjalmarsson on August 18, 2005, 9:35 am
Please log in for more thread options


Autumn-Fox wrote:
> I have two versions apache on my machine. If I start 1.3 version, I can
> run all the cgi files.
> If I start 2.2 version, I can't .

That was a rather important piece of info, don't you think?

> I really don't know what's wrong with all my cgi files.

Maybe the typo at line 87 ?

> Maybe it's a configuration problem.

That does sounds as a much more probable explanation to me.

Just can't understand why you posted to a Perl group about it. Try An
apache group instead.

--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl


Posted by Big and Blue on August 18, 2005, 9:51 pm
Please log in for more thread options


Gunnar Hjalmarsson wrote:
>> But I don't really know how to solve it.
>>
>> #!/usr/bin/perl
>> print "Context-type: text/html\n\n";
>> print "Hello EveryOne";
>>
>> --------------------------------------
>> Even this sample doesn't work.
>
>
> Try content-type.

Even more important- set the *correct* Content-type.

You're setting text/html then sending text/plain. Sort it out...


--
Just because I've written it doesn't mean that
either you or I have to believe it.


Similar ThreadsPosted
http request headers October 1, 2004, 12:47 pm
http headers with CGI.pm and mod_perl (bug?) November 10, 2004, 10:19 pm
XML::Twig parseurl with input Headers/XML January 16, 2005, 10:58 pm
Problem with CPAN and tar file headers May 16, 2007, 4:57 am
HTML::TableExtract with headers constraint, exluding right-most column May 15, 2005, 3:31 pm
Parse tcpdump for HTTP Request Response Headers July 29, 2007, 2:10 pm
Net::Analysis Parse tcpdump for HTTP Request/Response Headers July 29, 2007, 6:41 am
2 cgi script executions, is it possible? July 11, 2005, 8:01 pm
Script debugging June 24, 2006, 12:06 am
script to calculate CRC-32 of bitstream December 8, 2004, 5:20 am

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap