CryOfFaclon
CryOfFaclon

Reputation: 249

Why slider won't stop on hover

I am using responsive slider it won't stop on hover, I don't understand why, here is my script to tell it to pause on hover

<script type='text/javascript'>
 $(function () {
    $(&quot;.rslides&quot;).responsiveSlides({
  timeout: 8000,                  
  pause: true, 
});
  });
</script>

Here is live demo to the page where it is implemented http://bloghutsbeta.blogspot.com/2012/04/testing-slider.html

Relevant Markup:

<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script src='http://files.cryoffalcon.com/javascript/responsiveslides.min.js' type='text/javascript'/>

HTML:

<ul class="rslides">
<li><img width="660" height="400" src="http://responsive-slides.viljamis.com/1.jpg" alt="" /></li>
<li><img width="660" height="400" src="http://responsive-slides.viljamis.com/2.jpg" alt="" /></li>
<li><img width="660" height="400" src="http://responsive-slides.viljamis.com/3.jpg" alt="" /></li>
</ul>

CSS:

.rslides {
  position: relative;
  list-style: none;
  overflow: hidden;
  width: 660px;
  padding: 0;
  margin: 0;
height:400px;
  }

.rslides li {
  position: absolute;
  width: 660px;
height:400px;
  left: 0;
  top: 0;
  }

.rslides li:first-child {
  position: relative;
  display: block;
  float: left;
  }

.rslides img {
  display: block;
  height: auto;
  float: left;
  width: 660px;
height:400px;
  border: 0;
  }

EDIT: Link to the page of the creator of this plugin http://responsive-slides.viljamis.com/

Upvotes: 1

Views: 1002

Answers (2)

Viljami Salminen
Viljami Salminen

Reputation: 1

The problems is that you are using version 1.23 of that plugin and as mentioned in the changelog on GitHub that option was added in version 1.3. Take a look here and download the latest version: https://github.com/viljamis/ResponsiveSlides.js

Upvotes: 0

Yamiko
Yamiko

Reputation: 5453

<script type='text/javascript'>
 $(function () {
    $(".rslides").responsiveSlides({//use quotes
  timeout: 8000,                  
  pause: true//trailing comma taken out 
});
  });
</script>

Upvotes: 6

Related Questions