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

Duplicate style attribute generated on a DIV tag that replaces a UL tag.

From: Michael Goldberg <MGoldberg@yet2.com>
Date: Tue, 6 Nov 2001 10:37:14 -0800
Message-ID: <D090FE9586C9D4119E4E00A02493157A052F4A@ferris.tahoe.yet2.com>
To: "'html-tidy@w3.org'" <html-tidy@w3.org>
If I run the input at the bottom of this e-mail through Tidy, the <ul> tag
is converted to a <div> tag.  I presume this is being done because the <ul>
element does not have any direct <li> child elements.  That's probably OK,
but the problem we are having is with the following generated <div> tag:

<div style="margin-left: 2em" style='margin-top:0in'>

Why are there two style attributes?  Shouldn't the generated <div> tag only
have one style tag, with the contents of the <ul> style tag appended?  Is
this a bug?

Sincerely,
Michael S. Goldberg
mgoldberg@yet2.com <mailto:mgoldberg@yet2.com> 

Input:

<html>
<title>Test</title>
<ul style='margin-top:0in'>
 <ol style='margin-top:0in'>
  <li>One</li>
  <li>Two </li>
  <li>Three </li>
 </ol>
</ul>
</html>
Received on Tuesday, 6 November 2001 13:37:46 GMT

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