This way it will also catch https URLs. Though using a module as recommended below is probably the best way.$line =~ m{^https?://([^/]+)}; $server{$1}++; for ( keys %server ) { print "$_ : $server{$_}\n"; }
In reply to Re: Re: Parsing to get server info
by l2kashe
in thread Parsing to get server info
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |