Remove White-Space from HTML Except from <pre>'s
If you have ever used ColdFusion's function (<cfprocessingdirective suppresswhitespace="yes">), you may have noticed that it strips white-space formatting from any HTML <pre>'s you may have in the code. 99% of the time you would never have this problem, but if you have a programming blog, this can be some what of a hassle.
Well, as I was re-writing my cjboco.com site, I decided to take up the challenge and create a function using RegEx that ignore's anything in-between the <pre>'s. It will also remove any comments, but since I was using this to strip all the white-space out of my generated HTML, I soon realized this wasn't working to well with my conditional comments for Internet Explorer. Oh well, at least it's in here for future use. Let me know if you have any problems.