If you're already using LWP, you get slurp for free :)
#!/usr/bin/perl -- use strict; use warnings; use LWP::Simple; my $url = 'http://search.cpan.org/dist/Wx/META.yml'; my $file = 'temp'; mirror( $url, $file ); my $slurp = get( "file:./$file"); # print $slurp, "\n"; __END__

Replies are listed 'Best First'.
Re: Short free slurp for web clients
by wilsond (Scribe) on Jan 09, 2009 at 08:23 UTC

    For slurping, I use the following code. I don't know how well it works for gigantic files, but I wouldn't recommend trying, of course.

    open(FH, "<$filename"); my $slurp = join(undef, <FH>); close(FH);