jimmyshoes
Programmer
I'm experimenting with list based navigation
I want to use a list to generate the following
1 2 3
I am using the following code
The problem is that the float:left is for some reason causing the list to be rendered below the surrounding bordered div
Why is this?
I want to use a list to generate the following
1 2 3
I am using the following code
Code:
<style>
ul li{list-style:none;display:block;padding:10px;float:left}
</style>
<div style="border:1px solid #ffffff">
<ul>
<li>1</li>
<li>2</li>
<li>3</li>
</ul>
</div>
The problem is that the float:left is for some reason causing the list to be rendered below the surrounding bordered div
Why is this?