W3C home > Mailing lists > Public > html-tidy@w3.org > April to June 2007

Raw / no-fix / beatifier mode ?

From: Nathaniel Brown <nshb@inimit.com>
Date: Wed, 20 Jun 2007 13:23:39 -0700
Message-ID: <e5e181e80706201323n4be92e4bt974acb9abee0ed95@mail.gmail.com>
To: html-tidy@w3.org

I am looking for an option that I can run tidy against a html file to
simply beautify it. Right now when I run it, I see the warnings, and
it ends up fixing the HTML code. So if I have a missing div, or what
have you, it will add it or fix it.

Reason I ask is i want proper indenting in order to track down where
the missing div is. Preferablly, if it was able to determine the wrong
order of closing tags, it would use the proper nesting to indent the
raw code.

So if I have something like...

INPUT
---
<div id="one"><span><div id="two"><a>link</a></span></div>

OUTPUT
---
<div id="one">
   <span>
       <div id="two">
           <a>link</a>
   </span>
</div>

It wouldn't error out or warn me that id="one" is missing a closing
div as it would know that the first

Any ideas? Is Tidy the right solution for this task?

Nathaniel.

-- 
Nathaniel Steven Henry Brown

Toll Free: 1-877-446-4647
Vancouver: 604-724-6624
Received on Thursday, 21 June 2007 10:52:45 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 3 April 2012 06:13:56 GMT