This is what I have so far: http://jsfiddle.net/u8GHJ/
What I'm trying to do is attach the black border to the left side of the blue box. What is an easy way to achieve this? And no, I can't just add border-left:4px solid black;
to #container li
.
It should look like this: http://i.stack.imgur.com/oLBK8.png
Edit: I need to move the border to the container and not the opposite, so setting the padding to 0 won't help in this case.
There's default padding on the ul
element. To remove it, add ul {padding:0;}
( or #container {padding:0;}
) to your css and every thing will look peachy.
Check out your updated example here:
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.