in reply to Perl = reg Exp - Cut info in middle
I assumed that there are only two ':' in your string and you wanted the part between them.my $yourstring="someinfo:Info_to_cut:Take_me_off"; $yourstring=~/^.*?:(.*?):.*$/; $info=$1;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Perl = reg Exp - Cut info in middle
by ikegami (Patriarch) on Mar 23, 2006 at 16:35 UTC | |
|