CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Beginner: Re: [MDTech.us_MAN] Premature end of script headers: Edit Log



Kenosis
User

Feb 24, 2013, 9:14 PM


Views: 1618
Re: [MDTech.us_MAN] Premature end of script headers

...I checked everything.

Even the syntax?

perl -c script.pl
Can't find string terminator "HEAD111" anywhere before EOF at temp3.pl line 8.

For the here document, try:

Code
print <<HEADER; 

...

HEADER


Do the same for the footer. Also, you use some modules at the top of your script:

Code
use strict; 
use CGI;


Then later:

Code
use CGI; 
use CGI::Carp qw(warningsToBrowser fatalsToBrowser);


Place all the modules you use at the top of your script. Also, always:

Code
use strict; 
use warnings;


It's evident later in your script that you're attempting to parse form data. The CGI module you're using handles this, so use its methods. The Fool's Guide to CGI.pm, the Perl module for CGI scripting can assist you to better understand the features of CGI.pm.


(This post was edited by Kenosis on Feb 24, 2013, 9:18 PM)


Edit Log:
Post edited by Kenosis (User) on Feb 24, 2013, 9:17 PM
Post edited by Kenosis (User) on Feb 24, 2013, 9:18 PM


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives