Hi,
I added a scroll bar in div with a fixed height using css as follows:

#container {
    width: 1000px;
    margin: 0px auto;
}
#content {
    background-position: 190px 0px;
}
.central-content {
    padding: 0 1px 15px 1px;
    min-height: 500px;
    max-height: 500px; 
    overflow: auto; 
}

It works ok, but the problem is when I scroll down the picture up there also follows, and it overlaps pictures below. However, when I scroll up, the picture below do not go up. Only pictures on the top. Why? How can I fix it?

Recommended Answers

All 4 Replies

I think you must describe your problem better since people seem to not being able to understand your problem :) atleast I can't.

Please include the HTML

Member Avatar for diafol
min-height: 500px;
max-height: 500px;

Why not just use

height: 500px;

I doubt that this will solve the problem though. I second the call for your html.

#content {
background-position: 190px 0px;
background-attachment: fixed;
}

Hope this help!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.