in reply to Cleaning up HTML

Did you try HTML Tidy?

I don't know if it does all of what you want, but it does clean up HTML ;-)

Replies are listed 'Best First'.
Re^2: Cleaning up HTML
by bart (Canon) on Dec 20, 2007 at 13:22 UTC
    Yes I have. There's even a Firefox extension that incorporates it into the browser.

    The problem with HTML Tidy is that it does too much. It cleans up a lot of stuff I don't want it to touch, occasionally resulting in pages that just look a lot different. The page is just different HTML!

    I never even use it to update a plain HTML file. I only use it to have it tell me where the errors are, so I can clean it up manually.

    And now, I just want to clean up snippets, not a complete page. A lot of them.