Gallery Random: A Google Homepage Module
This is a simple Google homepage module that can display photos from
your Gallery2 based photo album on your personal Google web page.
You can customize the album that the photos will be selected from and
you can select how the random photos are chosen (e.g. recent albums,
random album, random photos, recent photos, etc...).
Requirements
You must be running Gallery2 and the photos you want to show must be
accessible without an account or password. You also need to have
the Image
Block module activated in your gallery.
Install
You can install
the module by clicking here.
Configuration
- Gallery URL: The URL to
your gallery (e.g.
http://my-domain.com/gallery2). Do not include anything after the
gallery directory. In particular do not include main.php or
anything after that.
- Root album: This must be
the numeric id of the album to select
photos from:
- It may be in the URL to your album page (e.g. if the URL to
your album looks like:
http://my-domain.com/gallery2/main.php?g2_view=core.ShowItem&g2_itemId=35
then you need to enter 35).
- If you use the rewrite module your URL's will not have the id
in them. In this case login to your gallery and choose "edit
album." Then look for the g2_itemId in the URL of the edit page.
- Max image size: This is
the size of the longest edge of the
images. e.g. 300 means that all images will be less than 300x300.
- What to show: Choose how
to select photos/albums.
- The following check boxes
determine what to show in addition to
the image. The title and date are the two that are most likely to
be useful.
- Number of items in cache:
To conserve bandwidth Google doesn't
download images from the gallery every time you load your
homepage. The number in this field will determine how many images
it will cache. If you want a new image every time (well, almost
every time, it is random after all) set it to a very large number, e.g.
20000. In general, it appears that Google refreshes a couple
times a day so a value of 5-10 should be more than sufficient and may
make your page load faster if your gallery is sometimes slow.
- Show debug URL: Select
this to display the URL that is being sent
to your gallery server.
Troubleshooting
If for some reason you're images are not showing up:
- Make sure you entered the URL correctly.
- Make sure you have the Image
Block module activated in your gallery.
- If you have embedded your gallery inside of another website
package, it is possible that this module will not work. I don't
have such a setup to test with. Let me know if you have troubles.
- Turn on "Show debug URL" in the options and copy and paste the
URL into your browser. It should bring up a page with your
image. If that works but the module doesn't show up send me mail and
I'll see what I can do.
Privacy
When you open your Google page, it will tell you that you need to allow
"inline" modules and that this may be unsafe. I can tell you that
the scripts give me no access to anything you enter and nothing is sent
to my server. Of course I'm the author so if I was trying to
hijack your information that's what I would have told you. You
can look at the source if you are up
to it, or you can just trust me. I really am a nice guy.
Links:
Contributions:
If you have suggestions about improving the module let me know.
If you are really excited about this module send me a note to say so,
and then donate to
the folks at Gallery that actually did all the hard work. You pay for
enough stuff you don't use, you may as well pay for something that you
do (I did).