Monday, November 5, 2012

CSS: horizontal ul li

HTML
<ul class="mylist">
<li id="active"><a href="#" id="current">Item one</a></li>
<li><a href="#">Item two</a></li>
<li><a href="#">Item three</a></li>
<li><a href="#">Item four</a></li>
<li><a href="#">Item five</a></li>
</ul>

CSS
.mylist li
{
display: inline;
float: left;
list-style-type: none;
padding-right: 20px;
}

No comments:

Post a Comment

Subscribe to RSS Feed Follow me on Twitter!