2021/12/11#p1
Dave Winer asked about using a regex query "to do a simple replacement that's complicated by the constraint that it can't do the replacement inside an HTML element, only in text that's not."
I have exactly the same query for a very similar purpose (part of the search function) but with an additional complication of using it within a MySQL query where different regex rules apply.