in reply to Re^2: Parsing multiple lines based on a given String
in thread Parsing multiple lines based on a given String

To read from a file handle, use the appropriate operator. To match a variable against a regex, you need to tell Perl what variable to match:
while (my $iphostname = <$fh>) { print $iphostname if $iphostname =~ /^object-group/ .. $iphostname + =~ /.../;

($q=q:Sq=~/;[c](.)(.)/;chr(-||-|5+lengthSq)`"S|oS2"`map{chr |+ord }map{substrSq`S_+|`|}3E|-|`7**2-3:)=~y+S|`+$1,++print+eval$q,q,a,

Replies are listed 'Best First'.
Re^4: Parsing multiple lines based on a given String
by ArifS (Beadle) on Jun 22, 2016 at 16:43 UTC
    Thank you. That helped.