Html Page Design using Css Basic

 



CSS


    CSS stands for Cascading Style Sheets. CSS is designed to enable the separation of presentation and content, including layoutcolors, and fonts.


    CSS could be added to HTML documents in 3 ways:

  1. By using Inner line.

    Example:
    <html>
    <head> 
    <title> </title>
    </head>

    <body>

    <h2 style="color:blue;"> Blue Colour</h2>


    </body>
    </html>

     



  2. By using Internal Style tag.

  3. Example:

    <html>
    <head>
    <title> </title>

    <style>
    p  {color: red;}
    </style>

    </head>
    <body>

    <p>This is a red colour.</p>

    </body>
    </html>

     




  4. By using External CSS file.
Example: 

body {
  background-color: powderblue;
}

h1 {
  color: w
hite;
}

 


This file save: "style.css"

<html>
<head>
<title> </title>

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


</head>
<body>

<h1>This is a Website</h1>

</body>
</html>

 


        
First
0 Komentar