Example:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
<style type="text/css">
#wrapper{font-family:arial}
</style>
</head>
<body>
<p>Some text</p>
<div id="wrapper">
<div id="header">some header text</div>
</div>
<p>Other text</p>
</body>
</html>
"Some text" and "Other text" appear as the default font (Times New Roman, in my case). #header does not have a style set, but inherits Arial from the wrapper.
What I normally do is something like this (from my site):
body
{
font-family: Georgia, "Times New Roman", Times, serif;
color: #5a5a5a;
font-size: 76%;
padding:0;
margin:0;
}
That stes the rules for the whole body. Then I set up new rules for each section or div.
If you haven't already, get the FireFox browser. When you see a site that you think has been styled nicely, hit Ctrl + Shift + C. Up pops all the css that's used on that page. Borrow it and apply it to a page of your own. Then change bits one by one to see what effect it has. That's the best way to learn.
Regards Mike
8 out of 10 questions have already been asked. Their answers can be found using Google. Go on, try it.If you prefer code samples or tutorials in another language, translate it for free at
www.codechanger.com