$foo = "abchelloxyz"; $foo =~ s/abc([\w]+)xyz/$1/; [download]
In reply to (wil) Re: regex: extract a substring by wil in thread regex: extract a substring by Galen