Introduction to CSS
CSS stands for Cascading Style Sheet. It is used to style our website. For Example, we add background color, buttons, change font size, etc.
Inline CSS:
We write CSS code under <style>tag. <style> tag also have a closing tag <style></style>. In beginning, we style our website under <body> tag.
For Example:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body style="background-color: red;">
<h4>Hello World</h4>
</body>
</html>
Copy this clipboard and paste it into your code editor then your result will came out and your background color will change to red.
You can also write a hexadecimal value to change your colors. If you want to check all hexadecimal value colors then the link is given below:
But the problem is that we write CSS code under the body tag. If we want to change font color we add CSS code under the body tag. It is very difficult to understand code under the body tag. So if you want to check another way to write CSS code then check my next note.
Nice introduction
ReplyDelete