Reputation: 5193
Yeah, I was wondering if there's a way to make a link the size of it's parent. See, I'm trying to make my drop-down menu's links stretch across the width of the .menu class they're embedded in. But it's not working even though I have everything else embedded in between as width: 100%;
Can anyone tell me how to make make my drop-down menu's links stretch across the width of the .menu class they're embedded in? Here is the link to my site
Upvotes: 0
Views: 146
Reputation: 34072
Make the links display: block;
You won't need the 100% width then (which will actually make the links too wide, because of the padding).
In general you'll want to be conservative with setting width 100% on elements, as with the standard box model that 100% does not include padding/margin/border on the element, and will often push it outside the bounding box of its parent.
Upvotes: 2