How HTML/CSS Borders Affect the Size and Layout of Your Webpage
Loading...
1,029
Loading...
Uploader Comments (waltdesignanddevelop)
see all
All Comments (2)
-
aww I really want to know this specific information because it's happening to me right now. but you use dreamweaver and I'm doing ti by hand. :(
Loading...
The effect is the same. If you have an element, and set it's width to 400px, then add a 2px border, your element is actually 404px wide (2px on each side).
[div id="element "][div id="innerElement "]...[/div][/div]
#element { width: 400px; border: 2px solid #000; }
Solution: add the inner element. #element { width: 400px;} #innerElement {border: 2px solid #000; }
Hope that helps.
waltdesignanddevelop 1 year ago