combdn
1/30/2014 - 10:27 AM

regexp-to-clean-table-markup

</?table[^>]*>|</?tr[^>]*>|</?td[^>]*>|</?thead[^>]*>|</?tbody[^>]*>

Extremely useful for cleaning up prehistoric mark-up with a text editor that supports regular expression find-and-replace searches.

And to go all the way, this one removes font tags too:

</?table[^>]*>|</?tr[^>]*>|</?td[^>]*>|</?thead[^>]*>|</?tbody[^>]*>|</?font[^>]*>

source: http://alex.tsd.net.au/2006/09/12/regular-expression-to-remove-html-tables/