Welcome to WebmasterWorld Guest from

Forum Moderators: not2easy

Message Too Old, No Replies

Float text at end of Unordered list?



8:47 pm on Nov 8, 2011 (gmt 0)

5+ Year Member

How do I get some text to go at the end of an unordered list instead of the line below?

total items...

I'd like to have it display like

1 2 3 total items

instead of

1 2 3
total items


9:28 pm on Nov 8, 2011 (gmt 0)

10+ Year Member

There are a number of ways you could do it but I suppose the simplest is to make them both display:inline.


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Untitled Document</title>
<style type="text/css">
.items li{display:inline}

<ul class="items">
<p class="total">total items</p>


9:31 pm on Nov 8, 2011 (gmt 0)

WebmasterWorld Senior Member penders is a WebmasterWorld Top Contributor of All Time 5+ Year Member Top Contributors Of The Month

Or float:left the list-items ?


9:36 pm on Nov 8, 2011 (gmt 0)

5+ Year Member

Thanks, that fixed it. I had one of my styles wrong. I had .pagination ul { instead of ul.pagination and it wasn't even applying it to my list. Thanks

Featured Threads

Hot Threads This Week

Hot Threads This Month