in reply to Simple regular expression that isn't simple

There are lots of good suggestions for you but I will expaling also a bit. As far as I know ">" isnt any special char in a regex is it? So you dont have to escape it. Then if you want to get all hits you will need the \g switch at the end of your expression along an array in front of your string to store all the hits. Then I guess you have forgotten that you need to remove "\n" if you want to store all the lines of a file in a single scalar. This has also been shown in an example in this thread.
  • Comment on Re: Simple regular expression that isn't simple