Im trying to do a regex where I can find all html tags, but for each one, each opening and closing tag must be the same. Heres what I mean: (Yes I only want max 3 letters)
preg_match_all("/\<[a-z]{1,3}\>(.*?)\<\/[a-z]{1,3}\>/", $string, $matches);
Where the 2 [a-z]{1,3}
are, I want those to be the same, so it doesn't match <b>
with <\i>
, etc. Thanks... let me know if you need further explanation