fbpx
Coding Basics WEB DEVELOPMENT

CSS TUTORIAL FOR BEGINNERS [INTRODUCTION]

CSS Tutorial

CSS Tutorial

Hello friends, Today I’ll give you intro to CSS.

What is CSS?

CSS is called cascaded style sheet. Which is used for designing web pages.

Before you learn about CSS you have to little bit idea about HTML.

HTML is used to make web pages. You can learn more about HTML by going to developersnation.co.in where you find a tutorial about HTML.

Its best place to start your web development journey.

So, I’m not going to tell you about everything about CSS but I’ll give you the best reference which is the best way to learn and develop web pages. Which is most developers do.

Watch This Tutorial on YouTube:

Let’s see how we use CSS in our web page.

So, basically there are 4 different way we can use CSS in our HTML code.

1 Inline Style.

2 Internal Style.

3 External Style sheet.

4 Import Command.

I’m going to teach you an external stylesheet. Which is beast for us? And every developer uses that.

First let’s see Structure of CSS.

Selector {
		Property: value;
}

Let’s see the example below

div{
	color: red;
	margin: 20;
}

In this case the div is selector. Which is written first and color is property. Yes you guess that red is the value;

So, we use link tag to include our CSS in the HTML. We use head tag to use our CSS document. It’s good practice to keep the CSS stylesheet as a standalone document.

This is HTML document. Don’t forget to save this document as .html format.

HTML CODE

This is CSS document you have to save this document as .css

CSS CODE

Output:

OUTPUT

Please share this post with your friend’s thank you.

Tip: Please do not forget to save the document if you don’t save the document it’s not going to work. And make sure you use the right formats, like .html for HTML documents and .css for CSS documents.

Question:

[wp_quiz id=”2768″]

Share This Post To Your Friends

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *