We know you have an opinion on how things should be run around here. These are suggestions for the forums, and the website.This forum is not a place to ask for suggestions to your own coding (or otherwise) problems.
phpbb runs the censoring filters at various (odd) times during display processing... since those changes are run through that system, they may and sometimes run at odd times. The system isn't set up to handle html, for one. Two, the filter is run on final html when quoting (last I remember) which makes it really poor then... but again, that's not really our fault, as more a fault in the implementation of their own system for censoring.