local($/, *WEB_DATA);#sets $/ to undef for you and when the scope exits it will revert $/ back to its previous value (most likely "\n") open (WEB_DATA, "<$myFilename.tmp"); my $myData = ; close (WEB_DATA); my @linkName = $myData =~ m/regexp for linkName/g;