PDA

View Full Version : Problem with aligning



AlCapwn
Mar 11th, 2010, 06:29 AM
I'm trying to align these two content boxes the ones labeled Sidebar(sd) and Main Body(bd) right next to eachother. Here is the code I have so far.


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"

"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<title>Mobster Services - Cheap, Fast, & Reliable</title>
<body bgcolor="black">
<head>
<style type="text/css">
div.ex
{
width:720px;
padding:0px;
border:2px dotted gray;
margin:50px auto 35px 200px;
}
div.sd
{
width:250px;
padding:0px;
border:2px dotted gray;
margin:auto auto auto 960px;
}
div.bd
{
width:720px;
padding:0px;
border:2px dotted gray;
margin:auto auto 500px 200px;
}
wh {color:rgb(255,255,255);}
h1 {font-size:40px;text-align:center}
p {font-size:14px;color:rgb(255,255,255);text-align:center}
</style>
</head>

<body>

<div class="ex"><h1><wh>Title</wh></h1></div>
<div class="sd"><p>Sidebar</p></div>
<div class="bd"><p>Main Body</p></div>

</body>
</html>

abduraooft
Mar 11th, 2010, 08:31 AM
Learn the trick from http://bonrouge.com/2c-hf-fixed.php