http://www.perlmonks.org?node_id=1000957


in reply to regexp to grab STRING...[everything here]...DIF STRING

Looks like frozenwithjoy already set you up with your regex, but I would suggest taking a look at perlintro (safety net) and begin using strictures in your code.

use warnings will save you time and frustration in debugging and use strict will help you write and maintain cleaner code. There are a multitude of nodes on PerlMonks that support the use of strictures.

use strict
why use strict is good, and barewords are bad
why you should use strict
Why use strict/warnings?