View Full Version : DIV tags help!
i'm fairly new to css AND dreamweaver so it's a pain getting around, anyways here's the basic layout i'm going for and I figured that the only way to do the nav is div tags, well I basically don't want to build the whole site with table, time to div it up!
the problem is when I keep adding my tags, they don't do what I tell 'em too! what's wrong with my code? I mean the side bar doesn't even show?!?!?
I've also attached a picture of the basic layout i'm going for so you can see exactly what i'm trying to do..
<head>
<title>Spud Design Studio</title>
<style type="text/css">
<!--
body {
background-color: #000000;
}
#nav {
text-align: right;
height: 659;
width: 106;
position:absolute;
left:50px;
top: 0;
background-image: url(images/navbar.gif);
}
-->
</style>
</head>
<body>
<div id="nav"></div>
</body>
</html>
jcdevelopment
04-10-2008, 09:26 PM
#nav {
text-align: right;
height: 659px;
width: 106px;position:absolute;
left:50px;
top: 0;
background-image: url(images/navbar.gif);
}
you need to specify px, em, pts...ets on height and width
hope that helps!!
that worked, thanks I feel dumb! hahaha..
jcdevelopment
04-10-2008, 09:31 PM
its cool, sometimes we need a fresh eye to look at things!
I hear ya! The only thing I don't understand is the clearing of floats really.. i've been at this for 24 hours building a few table sites so when I finally got to mine it's just my brian is mush!
<head>
<title>Spud Design Studio</title>
<style type="text/css">
<!--
body {
background-color: #000000;
}
#nav {
text-align: right;
height: 659px;
width: 106px;
position:relative;
left:50px;
top: -50px;
background-image: url(images/navbar.gif);
}
#nav{
height: 75px;
width: 91px;
position:relative;
left: 50px;
top: 300px;
}
-->
</style>
</head>
<body>
<div id="nav">
</div>
<div
<div id="nav2">
<p><img src="images/studio.gif" alt="studio" width="91" height="15" /><img src="images/portfolio.gif" alt="portfolio" width="91" height="15" /><img src="images/signdesign.gif" alt="sign design" width="91" height="15" /><img src="images/apparel.gif" alt="apparel" width="91" height="15" /><img src="images/contact.gif" alt="contact" width="91" height="15" /></p>
</div>
</body>
</html>
do I put the div into the other div for the blue and white nav images? when I go it like this it gets all messed up..
NEVERMIND! i'm a moron. fixed it! it was the id codes!
jcdevelopment
04-10-2008, 09:48 PM
haha, ok.. good luck!
how would I go about keeping a div FIXED in one location on screen?
another words, the nav bar I want to stay put (WITH THE BACKGROUND IMAGE AS WELL for the page) but I want the actual input of the page in the main part to be able to scroll and that's the ONLY thing that will scroll
jcdevelopment
04-10-2008, 10:16 PM
#nav{
height: 75px;
width: 91px;
position:fixed;
left: 50px;
top: 300px;
}
does that work?
vBulletin® v3.8.2, Copyright ©2000-2012, Jelsoft Enterprises Ltd.