I think that another bug will raise up once you fix this one. :s
Because, the $regsubexes are not named, it conflicts with previous $regmls and recalling for a previous match if another $regsubex was called. Therefore, just by naming differently each $regsubex, it shall be fixed. If that fixes future bugs, then great, otherwise, I\'ll help again. :)
(Or any other person who knows regexps !)
Cordialement