smather2175 - 9:44 pm on Oct 21, 2013 (gmt 0)
I'm trying to do something I see but can't seem to recreate.
I want to put a dashed border on a <div>. Dashed, dotted, solid, etc. doesn't really matter, I can handle that. What I want to do is have some space between the actual div dimensions and where the border is displayed.
With your basic CSS statement:
border: 2px dashed #2D72C2;
I get what you expect, a 2px, blue, dashed border at the very edge of the <div>.
What I want is some separation between the actual <div> dimensions and where the borer is displayed. The best way I can describe is if I had a <div> with the dimensions of 100px 100px 100px 100px with white background, and the above border statement I will get a border of the exact same dimensions around the <div>. What I want is for the border to actually display, centered, with dimensions something like 90px 90 px 90px 90px so that there is padding or space making the border be inside the <div> with a 10px space between <div> dimensions and border.
Is this possible with a property or do I need to create 2 separate <div> with the internal and slightly smaller one having the border?