0

here is the code to my .aspx page:

<body>
    <div class="left">
    </div>
    <div class="right">
        <div class="content">
        </div>
    </div>
</body>

here is the code to my stylesheet:

.left
{
    margin: 0px 0px 0px 100px;
    width: 550px;
    height: 100%;
    float: left;
    background-color: #FFFFFF;
}
.right
{
    width: 250px;
    height: 100%;
    float: left;
    position: fixed;
    background-color: #000000;
}

id like the div tag on the right to stay put, while my content scrolls with the page on the left. im looking for the simplest way to do this with css styling because ive heard it is very possible. i dont want to add a scrollbar or anything, id just like the div tag to act as a large black panel with navigation buttons centered that doesnt move as you scroll.

im building the site for a custom CMS that my fathers company wrote.

would appreciate any help.

2
Contributors
2
Replies
4
Views
7 Years
Discussion Span
Last Post by MJ Pieterse
1

you will need a overall container

CSS

.floatcontainerdiv {
  min-width:800px;
  max-width:100%;
}
.floatleftdiv {
  float:left;
  margin: 0px 0px 0px 100px;
  width:550px;
  max-width:74%;
  background-color: #FFFFFF;
}
.floatrightdiv {
  float:right;
  min-width:250px;
  background-color: #000000;
}
.content{
  width:96%;
  padding:20px;
}

you can style it accordingly

and then your HTML

<div class="floatcontainerdiv">
    	<div class="floatleftdiv">
        	     <div class="content">

                     </div>
               </div>
        <div class="floatrightdiv">
            <div class="content">
                
            </div>
        </div>
        <br style="clear:both" />
       </div>

Edited by MJ Pieterse: n/a

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.