detail of CSS3 programming language

ॐ CSS3 programming language ॐ 

👉text and background color:

👉Learn about:-

text and background color

CSS introduction:-

⃞  Css stands for cascading style sheets.

⃞   Describes the style of an HTML document.

⃞   It saves a lot of work. it can control the layout of multiple web pages all at once.

▢ It is used t define style for your web pages, including the design, layout and variations in display for different devices and screen sizes.

Tpye of CSS:-

1). In a separate .css file (external css). this is the recommended one 

eg:-

<link type="text/css" rel="stylesheet" href="path.css"> 

2). write inside the <style> tag (internal css)

eg:-

<style>

.clatest

{

color:red;

}

</style>

3). write the css properties with style attribute (inline css)

<div style="color:red;"> </div> 

Basic syntax of css:-

▢ CSS contains two parts: selector and declaration.

for example:

h1{

color: yellow; background-color: red;

}

selector- h1

Declaration

{color:blue;background-color:red;}

▢  the selector points to the HTML element where you want to add style.

▢ the declaration block contains one or more CSS properties separated by semicolons.

How to run in computer?

This file will not execute alone, it will  execute with . html file only. So we can follow the HTML run instruction as per the previous HTML.

<!doctype html>

<html>

<head>

<title> css programming language

</title>

<style>

.cls

back ground-color: red; color : yellow;

}

</style>

</head>

<body>

<div class="cls">

this is the test sample text 

</div>

</body>

</html>







 


Comments