I am attempting to align the final element in a list to the right side:
<ul>
<li>one</li>
<li>two</li>
<li>three</li>
<li id="right">right?</li>
</ul>
li {
display: inline-block;
margin: 0;
padding: 2px;
}
ul {
width: 300px;
list-style: none;
margin: 0;
padding: 0;
}
li#right {
text-align: right;
}
Unfortunately, it is not functioning as expected so I must be misinterpreting something crucial. What could it be?
You can view a fiddle of this issue here: http://jsfiddle.net/lborgman/b22g7/