18/03/2024 Education - Training
In CSS margins are used to control space around an HTML element.
Margins create space between other element and browser window
For individual sides(top, bottom,right,left) we can set different sizes of margins
Margins are completely transparent and doesn't have any background color
Margin properties can have the following values:
Length in cm, px, pt, etc.
Width % of the element.
Margin calculated by the browser: auto.
margin properties:
margin-top:Indicates the margin on the top of an element.
margin-right: Indicates the margin on the right side of an element.
margin-bottom:Indicates the margin on the bottom of an element.
margin-left: Indicates the margin on the left side of an element.
Note: The margin property allows negative values.
A **CSS Tutorial** helps beginners learn how to style web pages. CSS (Cascading Style Sheets) controls colors, fonts, layouts, and spacing, making HTM...
CSS (Cascading Style Sheets) is the backbone of web design, allowing developers to style and format HTML content. This tutorial guides beginners throu...
CSS (Cascading Style Sheets) is a stylesheet language used to control the appearance of HTML elements on a webpage. It allows you to add colors, fonts...
**CSS Tutorial: Style Your First Web Page** is the perfect beginner-friendly guide to learning how to add style and design to your website. This tutor...
More Details