×

Html & Html5

The World's best Software Development Study Portal

External style sheet


It means that you are having any different stylesheet in which you are doing the styling part of your HTML elements and this different style sheet is linked with your existing webpage. And this link we provide through <link> tag inside the <head> tag. And through this method our code will be well maintained and clear.
For Example:-

<!DOCTYPE html>

<html>

<head>

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

</head>

<body>

<p> Let's see here </p>

<p> I am Manish Singh Bhakuni </p>

</body>

</html>

This stylesheet can be written in any editor but it must be saved with the .css extension.
Here is our "main.css" file . Let's see:-


body{

     background-color:pink;

}

p{

      color:red;

      font-size:20px;

}


Output of the program


Let's see here


I am Manish Singh Bhakuni






CSS 3 training insitute | Best IT Training classes in Gurgaon | Web Designing Training Institute