Apply CSS to imported text/html

A

Anonymous

Guest
Hi, jogoland!

There are actually three (3) ways to do it:

(1) External Style Sheet when applied to many pages:

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

(2) Internal Style Sheet when applied to a single document:

Code:
<head>
<style>
hr {color: sienna;}
p {margin-left: 20px;}
body {background-image: url("images/background.gif");}
</style>
</head>

and (3) Inline Style:

Code:
<p style="color:sienna;margin-left:20px;">This is a paragraph.</p>

For the first one, you should create a file with the extension .css and link it in your HTML file. To learn more about CSS, you can visit this site: http://www.w3schools.com/css/default.asp

I hope this helps. Thank you.
 
Back
Top