in reply to Help constructing a regex that also matches hyphens and parentheses

None of this matches with a /td at the end because none of the test results have a /td. Otherwise they all test true.
#!/usr/bin/perl while (<DATA>){ print if(m#\s+((\w+\s*)+)</td>#g); } __DATA__ This is a test This is a (test) This is a (test123) this is a (123) This-is a test Just Another Perl Hacker </td>
  • Comment on Re: Help constructing a regex that also matches hyphens and parentheses
  • Download Code