W3C home > Mailing lists > Public > html-tidy@w3.org > July to September 2002

Request: a 'strip-presentation' option

From: Jelks Cabaniss <jelks@jelks.nu>
Date: Sat, 20 Jul 2002 18:25:05 -0400
To: <html-tidy@w3.org>
Cc: <Tidy-develop@lists.sourceforge.net>
Message-ID: <000d01c2303c$4cad44f0$6601a8c0@blackie>

There is, I think, currently only one glaring omission in Tidy.  Many
times, when we only want the *structural* markup, we need to get rid of
**ALL** presentational markup leftovers, including the embedded style
sheet.  Right now, the closest we can come to that is by applying
"clean" and "drop-font-tags", but that leaves droppings like this still
hanging around:

    <style type="text/css">
 	p.c1 {font-style: italic; text-align: justify}


    <p class="c1">...</p>

To get rid of this you have to manually delete the style section and
then do a regex search & replace to get rid of all the 'class=".*"'
attributes.  A 

	strip-presentation: yes/[NO]

option (or similar idea) would be extremely useful.  And rather than
have to set *two* options -- like 'clean' and 'drop-font-tags', which
you currently have to set to get even part of the way there -- it should
be a "one size kills all":  get rid of all FONT & CENTER elements,
ALIGN, BGCOLOR, & BACKGROUND attributes etc., and *not* replacing them
with CLASS attributes and *not* creating an embedded style section.


Received on Saturday, 20 July 2002 18:25:35 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:38:52 UTC