I have used the code from this question to create a horizontal menu where each item is evenly spaced.
Here is my version:
<div id="navigation">
<ul>
<li class="first">
<a href="#" title="Home Page">Home</a>
</li>
<li>
<a href="#">About us</a>
</li>
<li>
<a href="#">What we cover</a>
</li>
<li>
<a href="#">Monitoring agencies</a>
</li>
<li>
<a href="#">Publishers</a>
</li>
<li>
<a href="#">News</a>
</li>
<li>
<a href="#">Contact us</a>
</li>
<span></span>
</ul>
</div>
And the CSS:
#navigation {
text-align: justify;
}
#navigation ul span {
display: inline-block;
position: relative;
width: 100%;
height: 0;
}
#navigation ul {
display: inline;
list-style: none;
}
#navigation ul li {
display: inline
}
#navigation ul li a {
display: inline;
border-right: solid 1px #ccc;
}
#navigation ul li.last a {
border-right: none;
}
Is there a way to make the vertical lines move to the right such that they are halfway between the end of the a tags and the end of the li tags?
Here is a fiddle.
I've added an answer here.