SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Addict
    Join Date
    Feb 2003
    Location
    eez
    Posts
    331
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    1 question on the dl element

    Hi!

    Is this valid?

    <dl>

    <dd></dd>
    <dt></dt>
    <dd></dd>
    <dd></dd>
    <dd></dd>

    <!-- This is the first "group" of dt and dd elements (1st dd: alert above title; dt: title; 2nd dd, 3rd, dd, etc: title content) -->

    <dl><dd></dd>
    <dt></dt>
    <dd></dd>
    <dd></dd>

    ... continue like this

    </dl>


    Thanks!

  2. #2
    Programming Team silver trophybronze trophy
    Mittineague's Avatar
    Join Date
    Jul 2005
    Location
    West Springfield, Massachusetts
    Posts
    17,140
    Mentioned
    190 Post(s)
    Tagged
    2 Thread(s)

    valid

    Quote Originally Posted by aqw
    Is this valid?
    The best way to find out is to make a short sample of the mark-up you want to use and run it through the online validator.
    I have a page with this and it passes. (HTML transitional)
    HTML Code:
    ......
    <dt>Vulnerary</dt><dd>An agent used for healing wounds (f/d)</dd>
    <dt><br /></dt><dd></dd>
    <dt><b>Treatments:</b></dt><dd></dd>
    <dt>Clysters</dt><dd>Enema or injection (c)</dd>
    <dt><br /></dt><dd></dd>
    <dt><b>Conditions:</b></dt><dd></dd>
    <dt>Erysipelas</dt><dd>Inflammation and redness of skin</dd>
    ......

  3. #3
    bronze trophy
    Join Date
    Dec 2004
    Location
    Sweden
    Posts
    2,670
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Under HTML4 it is syntetically valid, yes, but it's semantically bogus. Each DD should have a relation to one or more DTs, and if you have DD as first child in the list then there aren't any DTs in the group.
    Simon Pieters


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •