=pod Embellish as you will (slurpall(), etc. This example only does one file at a time.) When I do this fast or in-line, many times I have accidentally left out the concatenation dot in ( .= ). Depending on your buffer size and file size, it can be a transient error that is a PITA. "Remember the dot". Better, package it. Reading a file a buffer at a time, rather than a line at a time, though, makes slurpping an invaluable tool of the trade (... $/="";). Usage: $html = slurp("index.html"); =cut sub slurp { my $tls = $/; $/=""; open X, $_ or return "No $_\n"; my $slurp .= $_ while (); close X; $/ = $tls; return $slurp; }