Hi there Guys
Hoping that someone can answer a few questions I have. A couple are really easy but one I think is a little more tricky!
What is the difference between calling a div as an ID or a CLASS???
I’m trying to layout the following page (excuse the colours, just there to make the divs visible. I want the ad div to be 10 px from the top and right of the content div. Please could someone tell me what i’m doing wrong.
Thanks!
[code=html]<!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=UTF-8″ />
<title>Untitled Document</title>
<style type=”text/css”>
#content
{
width: 800px;
background: #999999;
}
#menu
{
width: 100%;
background: #FF0000;
height: 30px;
}
#story
{
width: 80%;
background: #FFFFFF;
}
#ad
{
background: #FF9900;
width: 100px;
height: 45px;
position: relative;
top: 10px;
right: 10px;
}
</style>
</head>
<body>
<div id=”content”>
<div id=”menu”>
Menu 1 | Menu 2 | Menu 3
</div>
<div id=”story”>This is my really long boaring story to go on the home page. Blah blah blah. This is my really long boaring story to go on the home page. Blah blah blah. This is my really long boaring story to go on the home page. Blah blah blah. This is my really long boaring story to go on the home page. Blah blah blah. This is my really long boaring story to go on the home page. Blah blah blah. This is my really long boaring story to go on the home page. Blah blah blah. This is my really long boaring story to go on the home page. Blah blah blah. This is my really long boaring story to go on the home page. Blah blah blah. This is my really long boaring story to go on the home page. Blah blah blah. This is my really long boaring story to go on the home page. Blah blah blah. This is my really long boaring story to go on the home page. Blah blah blah. This is my really long boaring story to go on the home page. Blah blah blah. </div>
<div id=”ad”>
Ad here
</div>
</div>
</body>
</html>