Friday, 28 August 2015

How To Set Interval Two Image FadeIn and FadeOut Jquery


If You want to set two image in and first image come out and another image come in same place
in fadein and fadeOut Effect. I am Create Example for that.

Please Check that this code.

<script src="//"></script>
<script type="text/javascript">
 var cnt = 0;
         //var tmp = jQuery('ul li img');
       $('ul li img:eq('+cnt+')').fadeOut('fast', function(){
       cnt ==1 ? cnt=0:cnt++;
  $('ul li img:eq('+cnt+')').fadeIn('slow');

ul {
    list-style: none;


<img src="Gold-jewellery-jewel-henry-designs-terabass.jpg" width="500" height="500" />

<img src="e_original.jpg" width="500" height="500" style="display: none;" />

No comments:

Post a Comment

Thank You For Comment