In this code the LI elements have float:left and are aligned to the left of the container. I want to make them aligned to the right. How do I do this with CSS?
For example:
[…………………………….Item1.Item2]
Here is the HTML code:
<div class="menu">
<ul>
<li>Item1</li>
<li>Item2</li>
</ul>
</div>
P.S. The order of LI’s must not be reverse.
Try this
CSS
Or Use float:right to ul like
JSFiddle Example