how to embed data in perl programs
- From: sharan.basappa@xxxxxxxxx (Sharan Basappa)
- Date: Tue, 6 Feb 2007 20:55:59 +0530
Question is how to embed text in a perl program instead of reading it from a
file
or initializing the text in a string variable.
I have done the following but when I execute the script, I get no output.
Is there an issue I am overlooking ?
Another question is whether perl will replace the variable defined in
the embedded text with actual values ?
Thanks ..
#!/usr/bin/perl
my $one = "onex";
my $two = "twox";
while (<MY_BLOCK>)
{
print $_;
}
exit;
__MY_BLOCK__
once
upon
there was a person who was
very fond of $one and $two
- Follow-Ups:
- Re: how to embed data in perl programs
- From: John W. Krahn
- Re: how to embed data in perl programs
- From: Tom Phoenix
- Re: how to embed data in perl programs
- Prev by Date: Re: Extract user from email address
- Next by Date: Re: Extract user from email address
- Previous by thread: sql sERVER sYBASE
- Next by thread: Re: how to embed data in perl programs
- Index(es):
Relevant Pages
|