Activate online slide show on page load

I'am working my web page on "WYSIWYG Web Bulider", and on the main page I have inline frame, and when I click that inline frame another page is opened who has online slide show on It. I want that when that page is opened, online slide show is automaticly triggered. Probably I need some javascript code for that, but I'm not familiar with coding.

test web page is curently on croatian language, but just click the picture http://3dvizlab.com/test/3d_vizualizacija.php

This is html code of the page with online slide show

<!doctype html>
<html>
<head>
<meta charset="UTF-8">
<title>exteriors</title>
<style type="text/css">
body
{
   font-size: 8px;
   line-height: 1.1875;
   background-color: #FFFFFF;
   background-image: url(images/classy_fabric.png);
   color: #000000;
}
</style>
<style type="text/css">
a
{
   color: #0000FF;
   text-decoration: underline;
}
a:visited
{
   color: #800080;
}
a:active
{
   color: #FF0000;
}
a:hover
{
   color: #0000FF;
   text-decoration: underline;
}
</style>
<script type="text/javascript" src="jquery-1.7.2.min.js"></script>
<link rel="stylesheet" href="./prettyPhoto/css/prettyPhoto.css" type="text/css">
<script type="text/javascript" src="./prettyPhoto/js/jquery.prettyPhoto.js"></script>
<script type="text/javascript">
$(document).ready(function()
{
$("a[rel^='prettyPhoto_OnlineSlideShow']").prettyPhoto({theme:'facebook'});
});
</script>
</head>
<body>
<div id="OnlineSlideShow" style="position:absolute;left:352px;top:337px;width:300px;height:200px;z-index:0;">
<?php
   $images_folder = "../pictures/exteriors/";
   $image_width = 300;
   $image_height = 200;
   $count = 0;
   $dir = opendir($images_folder);
   while ($filename = readdir($dir))
   {
      $ext = pathinfo($filename, PATHINFO_EXTENSION);
      if ($ext == 'gif' || $ext == 'jpeg' || $ext == 'jpg' || $ext == 'png')
      {
         echo "<a href=\"$images_folder$filename\" rel=\"prettyPhoto_OnlineSlideShow[OnlineSlideShow]\">";
         echo "<img class=\"image\" alt=\"\" style=\"border-width:0;left:0px;top:0px;width:" .$image_width. "px;height:" .$image_height. "px;";
         if ($count != 0)
         {
            echo "display:none;";
         }
         echo "\" src=\"$images_folder$filename\">";
         echo "</a>";
         echo "\r\n";
         $count++;
      }
   }
?>
</div>
</body>
</html>

Answers


Change the function call to

$(document).ready(function()
{
   $("a[rel^='prettyPhoto_OnlineSlideShow']").prettyPhoto({theme:'facebook', ,slideshow:5000, autoplay_slideshow:true});
});

That should trigger the slideshow on load, with a delay of 5 seconds between slides.


Need Your Help

Default timezone for DateTime in asp.Net

c# asp.net

What determines the default timezone for a DateTime instance if no timezone is specified.

"foreman start" results in "Could not find bundler (>= 0) amongst..." error

ruby sinatra rack rbenv foreman

I copied an example Procfile from heroku's docs, and am trying to use foreman to run a Sinatra app locally.