Search code examples
jquerycsspositioncarouselfixed

how do I make only a portion of a fixed positioned div visible?


I created a fixed positioned div that has a very large width so that it can contain about 2 dozen company logos horizontally in a single line. As far as html goes, I just created a ul with one logo per li and then floated all of the li to the left. I used fixed positioning so the browser wouldn't create a scrollbar, and now I want only 800px in terms of width being visible at any one point in time, and logos that are on the line only being shown for the portion that is lying inside the 800px area. How do I do this? (I'm trying to make a custom carousel at the moment)


Solution

  • Place the list into a div, set the div width to be what you want and set scrolling to auto in the style of the div.

    i think that should do it