my $filedata; open( IN, '<', $filename ) or die "whatever. $!"; { local $/; $filedata = ; } close IN;