I am currently utilizing a basic slider plugin to generate a ticker bar resembling the following:
and then transitions to the next slide:
The functionality mirrors that of this "plugin," but my predicament is that the width
of the slider must occupy 100%
of the screen (unlike the fixed width
of 500px
in the plugin):
http://codepen.io/zuraizm/pen/vGDHl
I attempted to incorporate width: 100%
in the CSS for slider
, ul
, and li
, yet encountered no success:
#slider {
position: relative;
overflow: hidden;
margin: 20px auto 0 auto;
border-radius: 4px;
width: 100% !important;
}
#slider ul {
position: relative;
margin: 0;
padding: 0;
height: 200px;
list-style: none;
width: 100% !important;
}
#slider ul li {
position: relative;
display: block;
float: left;
margin: 0;
padding: 0;
width: 500px;
height: 300px;
background: #ccc;
text-align: center;
line-height: 300px;
width: 100%;
}
Any suggestions on how I can achieve the desired effect of width:100%
similar to the example images?