in reply to [Solved]: Can we use print <<HTML; twice in same file?

From perlop:
The terminating string must appear by itself (unquoted and with no surrounding whitespace) on the terminating line.
Change:
HTML; #stop HTML printing in chunk. But when this file is fetched from + browser, it displays everything starting from the following line unt +il next
to:
HTML

Replies are listed 'Best First'.
Re^2: Can we use print <<HTML; twice in same file?
by Tux (Canon) on Aug 25, 2015 at 15:57 UTC

    No, you quoted the text about the trailing tag. Just change <<HTML; #… to <<"HTML"; #…


    Enjoy, Have FUN! H.Merijn

      Did you try that?

      Adding the double quotes around the opening tag won't solve the OP's problem. When using a herdoc, perl will "assume" that double quotes were used if none were used.

        No, but I always quote. And use use 5.20.1; (or use strict;), use warnings; and Perl::Critic's perlcritic -1


        Enjoy, Have FUN! H.Merijn