I am trying to get my nav bar centered properly and with a 1px border on the left and right of each nav item (as opposed to 2px where two borders join together).
The site is www.berryconcept.co.uk/vouchfor
Any help would be appreciated.
Many thanks,
Tom
要在联结中没有双边框,可以给项目不带边框,而给:first-child
项目左边框: http : //www.w3.org/TR/css3-selectors/#selectors
In cases like this I generally proceed as follows:
I add the border for the first link as a border-left: 1px solid #ccc;
on either the <ul>
or the <div>
encasing the ul and then set it so each <li>
element has border-right: 1px solid #ccc;
set.
Hopefully this helps.
If you post your code on a jsfiddle I'll update it for you. :)
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.