jsymonkj / pwi

Automatically exported from code.google.com/p/pwi
0 stars 0 forks source link

Random image function / Latest album function #21

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
The latest photo function is great. But what about a random image and a
latest album function. For the latest album function I think it is good, to
have a link to the whole album screen or open the album in an pop up.

Original issue reported on code.google.com by schal...@gmail.com on 20 Sep 2009 at 2:38

GoogleCodeExporter commented 9 years ago

Original comment by jdiderik on 12 Nov 2009 at 8:22

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
random..I'm not gonna try and do this, not supported by Google API and manual 
work creates to much overhead.

Original comment by jdiderik on 12 Aug 2010 at 2:22

GoogleCodeExporter commented 9 years ago
Actually, depending on what you want, some pretty good randomization can be 
done by playing with the page and maxResults parameters. The best if you know 
in advance how many pages you will have, then you can just randomize which page 
to display out of those.

In my case I wanted to display random 7 photos spread out on 15 pages.

...
page: Math.floor(Math.random() * 15) + 1,
maxResults : 7,

View the example here (in greatest photos section):
http://www.simplyaroundtheworld.com/

Original comment by adam.mas...@gmail.com on 26 Jun 2011 at 6:08