Friday, February 3, 2012

How to add style sheet to an html page

How to add style sheet to an html page

How to add style sheet to an html page

  • Create a css file say index.css and add style to it
body{
@import url('https://fonts.googleapis.com/css?family=Tangerine&display=swap');
body{
font-family: 'Tangerine', serif;
    font-size: 48px;
}
  • In the header section of your html page, add the reference to the above css file path 
<!DOCTYPE html>
<html lang="en">
<header>
<link rel="stylesheet" href="index.css">
</header>
<body>
<div>your page content</div>
</body>
  • The style defined in the index.css file will be available on the page




  • Please do like and follow our facebook page here
  • For more queries, feel free to e-mail us here
  • Just to let you know, we are an Amazon Associate. To help and support us, you can shop for different products available on Amazon from here

No comments:

Post a Comment

SpringBoot Application Event Listeners

When a spring boot application starts few events occurs in below order ApplicationStartingEvent ApplicationEnvironmentPreparedEvent Applicat...