Originally Posted by eschwartz
Reread my regex. I did think of that.
Nitpick: I used an optional capture group, which includes a space (because as a general idea, I like demanding spaces after the tag name and before the attribute, to avoid matching the wrong tags) -- but your regex does not need a ? because the star already covers that.
Thank you all for looking into this error for me.