print problem

Discussion in 'Perl' started by bhavin12300, Apr 22, 2007.

  1. bhavin12300

    bhavin12300 New Member

    Joined:
    Apr 7, 2007
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    0
    hi
    i have created one pl cript and running it in windows using browser

    here is the simple code


    Code:
     #! /usr/bin/perl
       
       $obj=new CGI();
       print $obj->header();
       
       
       print <<"BHAVIN";
       
       
       
       
       <H1>HELLO WORLD
       
       
       BHAVIN
    and its it giving me following error

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

    Can't find string terminator "BHAVIN" anywhere before EOF at C:\Inetpub\Scripts\A.pl line 7.
     
    Last edited by a moderator: Apr 23, 2007
  2. pradeep

    pradeep Team Leader

    Joined:
    Apr 4, 2005
    Messages:
    1,645
    Likes Received:
    87
    Trophy Points:
    0
    Occupation:
    Programmer
    Location:
    Kolkata, India
    Home Page:
    http://blog.pradeep.net.in
    You need to have a blank new line after BHAVIN in the last line!
     
  3. bhavin12300

    bhavin12300 New Member

    Joined:
    Apr 7, 2007
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    0
    awsome
    its working now
    thank you
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice