Any chance anybody could whip up a random photo style plug-in (and by plug-in I mean line of php code). Better yet would be the option to choose "random photo" or "random photo from specific album".
And it might not make sense to simply pull a random photo. Instead it might be more useful to display the thumbnail for a random photo and then link directly to that photo within it's own album.
Thank you very much.
Hello,
I'm looking for ways on how to display random image per album. Is there a way to achieve this? There's no option for this in the program. There are about 200 photos in one album and viewers dont really go through all images on the albums so it's the same pictures are getting viewed. At least randow view based on file names.
Thank you.
Added at ticket 555
http://www.zenphoto.org/trac/ticket/555
It has been added to our extensions page http://www.zenphoto.org/2008/01/hacks/#random-image-external-site
The extension made by fatman is different from http://www.zenphoto.org/documentation-official/zenphoto/_template-functions.php.html#functiongetRandomImages right? How to set getRandomImages? Is this the line where I should set?
[code]$imageWhere = " AND " . prefix('images') . ".show=1"[/code]
Thanks.
fatman,
Thank you for this piece of code. I have few questions because I cant seem to make it work.
1.) I placed random.php under zp-core and tested on the browser using http://mylocalgallery.com/zenphoto/zp-core/random.php?
num=9&height=50&width=50. I also tried with "class=" but it's not working.
There are boxes of thumbnails but the pictures are not showing. It displayed the filename of the image. I got this "Zenphoto Error: the requested object was not found." error when I clicked on the thumbnail.
Please follow the links to our documentation I posted above. And maybe read this before: http://www.zenphoto.org/2008/04/how-to-read-the-zenphoto-functions-guide/
I would like to have fatman's random image display on external site but php is not my strength. Here is the code for a gif image (images/slikom.gif) which serves as the link to my zenphoto gallery. When you click the gif it opens page with gallery. I would like to have instead of that gif image random image by fatman that does the same job, takes you to the gallery.
This is code i have now to do the above described job:
`
[img]images/slikom.gif[/img]
`
Where should I put fatman's code for the external php site?
`@readfile('http://yourgallery.com/zen/zp-core/random.php?
num=15&height=120&width=120&class=one-image&album=damjanci-ponaosob')`
I already have random.php in place. Does random.php has to be edited in any way?
@fatman
It's working!!! Thank you very much. I would like to have it on click to open main zenphoto site instead of random photo you clicked on. That way visitors would be aware of all albums there. I guess this could be done with changing values in random.php but again I'm not sure which one should be changed. Could you please point me to that value?
I had succeed according fatman's method. please go mysite http://girlsspot.info and see the effection on the right bar. You may set up a table or frame.
Very nice web site and of course girls. The fatman's code works for me too but I was just asking what should I change to have the random image (on the external site) being linked to the main zenphoto site instead of to the full size random photo in the target album.