Categories:
Cloud (204)
Entertainment (11)
Facebook (43)
General (50)
Life (31)
Programming (64)
Technology (430)
Testing (4)
Tools (488)
Twitter (5)
Wearable (26)
Web Design (44)
Collections:
Other Resources:
CSS Box Model for Block Elements
What is the CSS box model for block elements on a Web page?
✍: FYIcenter.com
The CSS box model specifies that each block element, like <p> or <div>, on a Web page should be displayed as a set of 4 nested boxes as shown in the diagram below:
.
1. The "margin" box - The most outer box is called "margin", which has a transparent color. You can see through the "margin" box. The thickness of the "margin" box can be controlled by the "margin" properties.
2. The "border" box - The first inner box is called "border". The thickness and color of the "border" box can be controlled by the "border" properties.
3. The "padding" box - The second inner box is call "padding", which shares the background color of the element. The thickness of the "padding" box can be controlled by the "padding" properties.
4. The "content" box - The most inner box is called "content", which is used to display the content of the element. The size of the "content" box is controlled by the "width" and "height" properties. The background color of the "content" box is controlled by the "background" properties. the "padding" box can be controlled by the "padding" properties.
2015-05-17, 2196🔥, 0💬
Popular Posts:
Should I sign in to Google account after installing Google Chrome 55? When you run Google Chrome 55 ...
How to create a new PowerPoint Template? I have created a slide master and some useful slide layouts...
How to login to outlook.office365.com with a Browser? I have a company email account on Office365. I...
Why am I getting the "You now have two copies of a file" error from OneDrive for Windows? You will g...
How to create a command button to run my macro in slide show in PowerPoint? I have created a macro t...