我有以下Perl代码:
use strict;
use warnings;
use MIME::Lite;
use HTML::Entities;
use Time::localtime;
use Sys::Hostname;
my $ti = localtime;
my ($day,$month,$year)=($ti->mday,$ti->fullmonth,$ti->year);
my $HOSTNAME =hostname();
my $greeting = <<END_HTML;
<p style="width:600px;margin:0 100px"><font face="Arial" size="3"><strong>$month $day, $year</strong></font></p><br>
<p style="width:600px;margin:0 100px"><font face="Arial" size="3" color="#3a7df9"><strong>Status of Update on '$HOSTNAME' machine</strong></font></p><br>
END_HTML
my $html = '<table style="width:600px;margin:0 100px" border="1" BORDERCOLOR="#000000">
<thead><th bgcolor="#9fc0fb">Successful Update</th><th bgcolor="#9fc0fb">Failed Update</th></thead>
<tbody>';
它在Eclipse中运行良好,但是当我尝试从Windows批处理文件运行它时,它会因错误而失败:
无法找到字符串终结符&#34; END_HTML&#34;在EOF之前的任何地方
我该如何解决这个问题?