W3C home > Mailing lists > Public > html-tidy@w3.org > October to December 2001

RE: Allowing other tags...

From: Kipp Howard <khoward@courtlink.com>
Date: Fri, 16 Nov 2001 08:49:19 -0800
Message-ID: <588DDEA4CC3AD411AE5200508BC5D2110A0570@hqmsx01.internal.courtlink.com>
To: "'Hans Deragon'" <deragon@aqiii.org>
Cc: html-tidy@w3.org
Hans Deragon [mailto:deragon@aqiii.org] wrote:
> Kipp Howard wrote:
> 
> >FWIW:  I haven't necessarily done the above but we do add 
> some tags to HTML
> >files that give us some additional information about the 
> files.  We do this
> >by adding <div> and <span> tags with very specific 
> attributes so that these
> ><div> and <span> tags are not confused with existing tags.  
> This means we do
> >not have to have any new tags that tidy does not support.  
> Here is a short
> >example:
> >
> ><div title="myConfigInfo">
> >	<span title="color">red</span>
> >	<span title="size">medium</span>
> ></div>
> >
> >Then when we are using the DOM/XSLT, we just select these 
> elements with:
> >//div[@title='myConfigInfo]/span[@title="color"]
> >
> >Just thought this might help make your job a bit easier by 
> not having to
> >modify how tidy works.
> >
> 
> Mmm...  I do not understand where you are going at.  If you pass your
> <div> and <span> to jtidy, jtidy will complain.  So you are 

It shouldn't complain since <div> and <span> tags are part of the XHTML
strict specification.  BTW, we are using the normal tidy application and not
jtidy.

> suggesting 
> that I do
> what within my html files?

Before running our html files through tidy, we add these tags to the top of
the file.  Since they are outside of the <HTML><BODY> elements, tidy moves
them inside those elements and make the rest of the html XML conformant.
Now you have a valid XHTML file that you can access with the DOM.  

In your case, since you are using templates, you could place <div>/<span>
tags in various locations throughout your html template and have your code
use the DOM to replace those tags with the values you desire.


-- 
Kipp E. Howard - OEM Development Engineer @ CourtLink
kipp.howard@courtlink.com   
(425) 372-1837 or (800) 774-7317 ext 1837 

 
Received on Friday, 16 November 2001 11:50:21 GMT

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