• Resolved mzimmers

    (@mzimmers)


    Hi, all –

    I’m using the “soccer” theme, which has some HTML validation glitches. In the sidebar, the author uses a class “bottom” for putting a small finishing picture below a list:

    .bottom {
            background: url(images/sidebar-bottom.jpg);
            height: 8px;
    	}

    The problem is, he uses it like this:

    <h3>Categories</h3>
    			<ul>
    				<?php wp_list_cats('sort_column=name&optioncount=1&hierarchical=0'); ?>
    				<div class="bottom"></div>
    			</ul>

    The validator barfs on putting a div tag within a ul tag. What might be a preferred way of doing this?

    I tried contacting the author, but got a mail failure message.

    Thanks.

Viewing 3 replies - 1 through 3 (of 3 total)
  • <h3>Categories</h3>
    			<ul>
    				<?php wp_list_cats('sort_column=name&optioncount=1&hierarchical=0'); ?>
    
    			</ul>
    
    <div class="bottom"></div>

    that’s the obvious answer (but not neccessarily the right one – whats that look like?

    Thread Starter mzimmers

    (@mzimmers)

    I tried that — it introduces a line between the list items and the bottom. See this example:

    example

    Thread Starter mzimmers

    (@mzimmers)

    Update: I was able to partly work around this by transferring the bottom-margin property from the list to the bottom element. Not perfect (since it requires every entry in the sidebar to have a bottom) but at least it should pass validation.

    Marked resolved.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘better way to “finish” a list?’ is closed to new replies.