Have u ever wanted to have a horizontal unlimited scroller to showcase items on your site? Here I have discussed how it can be achieved,

First of all HTML, 

  • Friend 1
  • Friend 2
  • Friend 3

    You can horizontally place list items by floating the list items to left and dynamically assign the container's width to product of number of items and width of individual item. This should look something like

    .friends-list li{
      float: left;

    $('.friends-list').width($('.friends-list>li').length * 180); // 180 is the width of each item

    That done and some css to remove vertical scroll and add horizontal scroll to the container of the list, looks something like,

      overflow-x: auto;
      overflow-y: hidden;
      width: 100%;

    To convert mousewheel scroll to scroll content horizontally instead of vertically we require.

    1. jQuery
    2. jQuery.Mouswheel Plugin
        if(e.originalEvent.wheelDelta < 0){