This sounds like excellent advice. I am going to rethink my naming
convention as well as the way this list needs to be broken up. 

Thanks for sharing your knowledge,
Kevin 

-----Original Message-----
From: li...@webstandardsgroup.org [mailto:li...@webstandardsgroup.org]
On Behalf Of Paul Novitski
Sent: Tuesday, September 22, 2009 1:51 PM
To: wsg@webstandardsgroup.org
Subject: RE: [WSG] Ordered List Best Practice

At 9/22/2009 08:43 AM, Kepler Gelotte wrote:
><ol type="A">
>   <li><a href="a.pdf">First</a>
>     <div class="margin_left_minus_40px">
>       <h3>Subheading</h3>
>     </div>
>   </li>
>   <li><a href="b.pdf">First</a></li>
>   <li><a href="c.pdf">First</a>
>     <div class="margin_left_minus_40px">
>       <h3>Subheading</h3>
>     </div>
>   </li>
>   <li><a href="d.pdf">First</a></li>
>   <li><a href="e.pdf">First</a></li>
></ol>


I find this solution problematic. Scrutinizing the markup, I would put a
subhead at the beginning of the content it heads, not at the tail of
whatever content precedes it.

Semantically, if items d & e deserve their own subhead, to what extent
are they really part of the same list as a, b, & c? They might be on the
same nesting level, but are they really part of the same list? It would
be interesting to see some of the actual content of this list to see why
the original poster felt that all five items belong in one list.

I guess the bottom line here is that today's HTML doesn't permit us to
insert a headline into the middle of a list but gives us this solution:

ol
    li
       ol
          li a /li
          li b /li
          li c /li
       /ol
       h3 subhead /h3
       ol
          li d /li
          li e /li
       /ol
    /li
/ol

>     <div class="margin_left_minus_40px">
>       <h3>Subheading</h3>
>     </div>

Aside, is the div really necessary? Could not any necessary styling be
applied to the h3 itself? If complicated markup is deemed necessary, for
example because of multiple background images < CSS3, I myself would
rather nest structures inside the headline rather than hang them outside
of it so as to reach for a greater semantic clarity.

Also, I suggest you use class names that evoke the purpose of a
structure and not its presentation. If your class names are going to be
as explicit as "margin_left_minus_40px" then you're no better off than
injecting style rules inline. Either way, if you change the graphic
design you'll be changing your markup. In this particular example you
likely don't need class names at all because you can specify the divs
and h3s unambiguously from their position in the markup, e.g.

         ol.listName li h3

Regards,

Paul
__________________________

Paul Novitski
Juniper Webcraft Ltd.
http://juniperwebcraft.com 



*******************************************************************
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: memberh...@webstandardsgroup.org
*******************************************************************



*******************************************************************
List Guidelines: http://webstandardsgroup.org/mail/guidelines.cfm
Unsubscribe: http://webstandardsgroup.org/join/unsubscribe.cfm
Help: memberh...@webstandardsgroup.org
*******************************************************************

Reply via email to