CSS Tutorial

CSS Margin

CSS Margin At times, we need to have some space around the element, we can simply put some margin on the required, or all sides of the element. For achieving this, we are going to make use of the margin-related properties. By the margin, we just mean that we are creating some space around the […]

CSS Margin Read More »

CSS Padding

Padding in CSS Padding simply means creating some space around the element’s content, inside the element’s border. When it comes to padding, with some different properties, we are able to generate space around the content of the element, inside the borders. Here are some properties related to padding. these properties have the following values –

CSS Padding Read More »

CSS Borders

CSS Borders The border properties specify the things related to the border. Whenever we need to set the border for some element, we can make use of the border properties. Here, we can set the border style, border color, and border width as well. Let’s have a look at all of them one by one.

CSS Borders Read More »

CSS Colors

Color in CSS Many times, we need to give some colors to some elements, like while changing the color of some text, or some background color, or while specifying the color of shadow, etc. So, we can do it in some different ways as well. One standard way that we have been practicing, is just

CSS Colors Read More »

CSS Comments

Comments The comments are just used to specify what we are doing in some particular line. This also helps us understand the code better. The comments are ignored by the browser. So, when you are writing the CSS rules, you can write the description of the rules inside the comments. As stated earlier, the comments

CSS Comments Read More »

CSS Background Shorthand Property

CSS Background Shorthand Property So far, we have seen many different properties related to backgrounds, like background color, background image, background-repeat, background-attachment, background-position, background-size, and background clip. If we are willing to set the values for all the background-related properties at once, we can make use of the background shorthand property. It is as if

CSS Background Shorthand Property Read More »

CSS Background Size

CSS Background Size Property Now, let’s have a look at the property related to background, which is background size. Well, when we are giving some background image, we are having control over deciding whether or not the image repeats. But if we have set the background-repeat to no-repeat, then the image that we have set

CSS Background Size Read More »