So, I’m trying to write a nice bit of regex to handle finding anchor
tags in
a bit of html.
This is what I’ve got…
/<[aA][^>]>[^<]</[aA]>/
I’m planning on using this with a gsub!.
Here is what it has to do…
Anything in here.As you can see, the regex I have will indeed work for this instance. It
will
match with ‘Anything in
here.’
Except, here is where it fails…
Anything in here.I still need ‘Anything in here.’
This regex doesn’t work…
/<[aA][^>]>.</[aA]>/
Because my middle tag will just keep going and return
because it doesn’t have any reason to stop.
Any suggestions?
-hampton.