You might consider a proper way of doing it ... regexes get just more complicated and still don't get everything right in this case. mirod had a very recent post about this topic: Re: HTML and XML.
-- Hofmator
In reply to Re: HTML to xHTML
by Hofmator
in thread HTML to xHTML
by spm
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |