jquery - Ajax fadein ipcam pictures (smooth crossover) -
i need help. unfortunately scripting skills limitated. running soccer blog , we've installed our ip-camera. got working except 1 littlie thing: have smooth picture crossovers on webpage: http://www.blickpunkt-muenster.de/webcams/webcam-6.php
i've solved embedding via ajax request cannot fadein function work though have googled lot. can me. awesome!!!
my blog: http://bwa-blog.de/bwacam/
my script:
<!doctype html> <html lang="en"> <head> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js"></script> <script> $(function () { window.setinterval(function () { var path = 'http://bwa-blog.de/bwacam2/ipcam.jpg?' + (new date()).gettime(); $('#demo').attr('src', path); }, 10000); }); </script> </head> <body> <img id="demo" src="http://bwa-blog.de/bwacam2/ipcam.jpg"/> </body>
made it. thing first refresh not overlay total fade out , fade in. if knows how fix id happy duck :)
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js"></script> <script>/*<![cdata[*/ $(function () { window.setinterval(function () { var path = 'http://bwa-blog.de/bwacam2/ipcam.jpg?' + (new date()).gettime(); $('#demo').attr('src', path); }, 10000); });/*]]>*/ </script> <script> /*<![cdata[*/ $(document).ready(function() { $(".featured > div:gt(0)").hide(); setinterval(function() { $('.featured > div:first').fadeout(2000, function() { $(this).appendto('.featured'); }).first().fadein(2000); }, 10000); });/*]]>*/ </script>
.featured > div { position: absolute !important; width:1170px; margin-top:0px !important;}
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> <div class="featured"> <div id=one> <img id="demo" src="http://bwa-blog.de/bwacam2/ipcam.jpg" style="border: 1px solid #bababa;"> </div> <div id=one> <img id="demo" src="http://bwa-blog.de/bwacam2/ipcam.jpg" style="border: 1px solid #bababa;"> </div>
Comments
Post a Comment