(2014-12-15, 04:42:28)shawn_a Wrote: I am pretty sure it does support callback or callout functions that allow random selection of a galleries images from a gallery. perhaps i am thinking of thumbs
http://get-simple.info/forums/showthread...9#pid44559
But I also remember reading something else, either way using your own code with galleries is still easier than pulling files from filesystem, as you can setup galleries and pull random from those instead.
It links to a gallery, so you can post one thumb in any size which links to a gallery, or you can post a thumb which links to a gallery via fancybox-popup. I don't want an image link, I only want a random image. But correct me if I'm wrong, I searched for this info in the thread and Mvlcek's own info-pages, but could not find what I want.
(2014-12-13, 02:44:46)Lars Wrote: This should work...Thanks, that works.
<?php
global $args;
$dir1=$args[0];
$dir=GSDATAUPLOADPATH.$args[0];
$files1 = scandir($dir);
$a=rand(2,count($files1)-1);
echo "<img src='".get_site_url(false)."data/uploads/".$dir1."/".$files1[$a]."' width='100%'>"
?>