The simple, but presumably wrong, answer is that the file contents can just be slurped into a string and the string passed to the subroutine. Why is that the wrong answer?
open infile, "< datafile"; my $str = join "", <infile>; close infile; gnuplot (..., $str);
In reply to Re: file contents as a part of code?
by GrandFather
in thread file contents as a part of code?
by djwaddel
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |