Pathologically Eclectic Rubbish Lister | |
PerlMonks |
Load file into a scalar without File::Slurpby BlueLines (Hermit) |
on Jun 28, 2000 at 23:22 UTC ( [id://20235]=CUFP: print w/replies, xml ) | Need Help?? |
File::Slurp allows you read a filehandle into a scalar.
However there is another way to do this without having to load an extra module at runtime.
The select statement changes $/ (the input record separator) to a null character instead of a \n. And there you go..
Back to
Cool Uses for Perl
|
|