I'm working on a little flash slideshow for my site as can be seen here
http://www.windsurf.me.uk/slide.phpIt currently uses 4 files:- slideshow.php, slideshow.swf, slide.php and source.php
Slide.php is the final webpage and is simply this code.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>
<BODY bgcolor="#FFFFFF">
<?php
//include slideshow.php in your script
include "slideshow.php";
//insert the slideshow.swf flash file into the web page
//tell slideshow.swf to get the slideshow's data from sample.php created in the first step
//set the slideshow's width to 320 pixels and the height to 240
echo Insert_Slideshow ( "slideshow.swf", "source.php" , 320, 240 );
?>
</body>
</html>
The bit I'm having trouble with is source.php. I would like it to randomly select 15 images from the coppermine gallery on my site and input these into the slideshow but I'm just not sure how to do it. I'm guessing cpmfetch will do the trick.
Here is the source.php code that selects the images at present. It currently just selects 3 fixed images and is self explanatry.
<?php
//include slideshow.php to access the Send_Slideshow_Data function
include "slideshow.php";
//add 3 slides
$slideshow[ 'slide' ][ 0 ] = array ( 'url' => "../Images/normal_loop.jpg" );
$slideshow[ 'slide' ][ 1 ] = array ( 'url' => "../Images/normal_IMG_0051AR.jpg" );
$slideshow[ 'slide' ][ 2 ] = array ( 'url' => "../Images/Andy Leeks.jpg" );
//send the slideshow data
Send_Slideshow_Data ( $slideshow );
?>