Anish Kumar K. wrote:
Hi

Hello,

The following program has to print in the CGI...I use perl
as well as HTML inside...

When I complile this I get the error as "Can't find string
terminator "ERROR_PRINT" anywhere before EOF"

Please help me and also. if there is such combinations like
perl CGI and HTML which is the best ways..
is it better to use labels like I used now...


if ($#xmlResponseError>0) {
print <<"ERROR_PRINT";
<TR><TH>The Following Users Error</TH></TR>
ERROR_PRINT

Both of the ERROR_PRINT labels have to match so either:

print <<"  ERROR_PRINT";
  <TR><TH>The Following Users Error</TH></TR>
  ERROR_PRINT

Or:

print <<"ERROR_PRINT";
  <TR><TH>The Following Users Error</TH></TR>
ERROR_PRINT


for (my $i=0;$i<$#xmlResponseError ;$i++) {
print << "ERROR_PRINT";
<TR><TD>
ERROR_PRINT

Either:

   print << "   ERROR_PRINT";
   <TR><TD>
   ERROR_PRINT

Or:

   print << "ERROR_PRINT";
   <TR><TD>
ERROR_PRINT


if (($i%3)==0) {
print << "ERROR_PRINT";
<BR><HR><BR>
ERROR_PRINT

Either:

     print << "     ERROR_PRINT  ";
     <BR><HR><BR>
     ERROR_PRINT

Or:

     print << "ERROR_PRINT";
     <BR><HR><BR>
ERROR_PRINT


    }
    print $cgi->p($xmlResponseError[$i]);
   print << "ERROR_PRINT";
   </TD></TR>
   ERROR_PRINT

Either:

   print << "   ERROR_PRINT";
   </TD></TR>
   ERROR_PRINT

Or:

   print << "ERROR_PRINT";
   </TD></TR>
ERROR_PRINT


  }
 }

And since none of the strings above involve interpolation you could use single quotes (') instead of double quotes (").




John
--
use Perl;
program
fulfillment

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>




Reply via email to