View Single Post
  #4 (permalink)  
Old 03-28-2008, 07:58 PM
lisa's Avatar
lisa lisa is offline
Administrator
 
Join Date: Apr 2007
Location: Dallas, TX
Posts: 4,672
lisa is the Admin and cannot be rated.
Default

Here's the basic CSS I used to get the right column to float. It's easier for me to just post what I did rather than try to explain why yours won't work. I'm still learning myself so I'm not good at troubleshooting CSS just yet.

Code:
<body> 
<div id="container">
<div id="header">
<div id="leftnav">
<div id="sidebar"> (This is my right sidebar)
<div id="content">
</body>
The CSS attributes for my right sidebar are as follows...

Code:
#sidebar {
    padding: 10px;
    float: right;
    width: 130px;
    background-color: #F2F4CA;
Of course the width numbers are going to vary for you. I just had to keep playing around until everything fit the way I want it. You just have to remember if you use padding then you have to add those padding numbers onto the width.

In other words if your entire site is 850 pixels and you have your left nav set to 130 with 10 pixels of padding, then your left column is really 140 pixels (130 + 10 + 10) so you need to keep that in mind when trying to get everything to fit.

Not sure if that helped or confused you even more. LOL
__________________
Don't put the cart before the horse.
Plan your website, then create it.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2 Create a Website | 2 Create a Website Blog
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Recent Blog Posts...

Twitter 101 [Video]
My Must-See Blog Posts From 2008
The Problem With The Word "Expert"

Reply With Quote