Skip to content

Instantly share code, notes, and snippets.

@CodeMyUI
Created Jan 30, 2017
Embed
What would you like to do?
simplyscroll
<ul id="scroller">
<li><img src="http://logicbox.net/jquery/simplyscroll/assets/20080514_JYW68XPT_tb.jpg" width="290" height="200"></li>
<li><img src="http://logicbox.net/jquery/simplyscroll/assets/20080608_38CG51J2_tb.jpg" width="290" height="200"></li>
<li><img src="http://logicbox.net/jquery/simplyscroll/assets/20080513_4D3SD1BQ_tb.jpg" width="290" height="200"></li>
</ul>
$("#scroller").simplyScroll();
<script src="//cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
<script src="http://logicbox.net/jquery/simplyscroll/jquery.simplyscroll.min.js"></script>
/* Container DIV - automatically generated */
.simply-scroll-container {
position: relative;
}
/* Clip DIV - automatically generated */
.simply-scroll-clip {
position: relative;
overflow: hidden;
}
/* UL/OL/DIV - the element that simplyScroll is inited on
Class name automatically added to element */
.simply-scroll-list {
overflow: hidden;
margin: 0;
padding: 0;
list-style: none;
}
.simply-scroll-list li {
padding: 0;
margin: 0;
list-style: none;
}
.simply-scroll-list li img {
border: none;
display: block;
}
/* Custom class modifications - adds to / overrides above
.simply-scroll is default base class */
/* Container DIV */
.simply-scroll {
width: 576px;
height: 200px;
margin-bottom: 1em;
}
/* Clip DIV */
.simply-scroll .simply-scroll-clip {
width: 576px;
height: 200px;
}
/* Explicitly set height/width of each list item */
.simply-scroll .simply-scroll-list li {
float: left; /* Horizontal scroll only */
width: 290px;
height: 200px;
}
<link href="http://logicbox.net/jquery/simplyscroll/jquery.simplyscroll.css" rel="stylesheet" />
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment