I have a container div .parent with a fixed width 500px which contains a lot of child divs .child.
The problem is that the child divs are getting auto wrapped, in my case i want them to continue in one line even if they’ll be hidden and after that i’ll add custom buttons to horizontally scroll the .parent div.
Demo: http://jsbin.com/egohi3
How to achieve that with keeping the floating?
Thanks
Make the parent element have
white-space:nowrapand the child elements to bedisplay:inline-block(instead of floating). Here is a modified example: http://jsfiddle.net/7we5q/