FlickrViewer

Configuration

Once you've installed FlickrViewer you must configure it before it will work. You must complete the following configuration options:

apikey

FlickrViewer uses the Flickr API to get information about your photos. To use the Flickr API you must have an API key. The API key is free, but you must apply for it. (The key is provided straight away -- no need to wait.) You can get an API key here.

Note that the API key must be enclosed in quote marks.

Example:

$apikey = 'abc45123def12ef3123123acbadbb12';
setid

What is the set ID for the photos you would like to display? All photos must be public and added to this set.

The Set ID can be got from the set url. For example, the Set ID for the following photo set is 72057594052387557:

http://www.flickr.com/photos/markymoo/sets/72057594052387557/

Note that the Set ID must be enclosed by quote marks.

Example:

$setid = '72057594052387557';
userurl

What is the URL of your main photo page? FlickrViewer need this so that it can link through to your photos. For example, here is mine:

http://www.flickr.com/photos/markymoo/

Note: Don't forget the trailing slash.

Example:

$userurl = 'http://www.flickr.com/photos/markymoo/';
cache

FlickrViewer needs a place where it can write a temporary file. This is used to cache the XML generated by FlickrViewer so that your website performs more quickly. This prevents the Flickr API being queried every time someone looks at your photos.

Note that the web server process must be able to write to this file.

Example:

$cache = '/tmp/flickr.xml';
ttl

TTL stands for 'time to live'. In other words it is the maximum cache age that is acceptable. Set the maximum age of the cache file in seconds.

This only needs to reflect the frequency you update your photo set, so setting the value to equal a day will work fine.

Example:

$ttl = 43200; // 12 hours

If you have problems writing the cache file to your web server, you may need to turn caching off. This isn't recommended as it will slow your site down, but if you must, set the cache life to zero.

Example:

$ttl = 0; // caching off
title

Set the title that will appear just above the thumbnails in the SimpleViewer flash file.

Example:

$title = 'My Favourite Photos';
showImageLink

This allows you to turn the link through to the Flickr photo page (comments page) on or off. Setting it to true will leave the link there, and setting it to false will remove the link.

Example:

$showImageLink = true; // link present (recommended)

Example:

$showImageLink = false; // link removed
showImageCaption

Use this to turn the image caption/title on or off. Set to true to leave the caption present, or false to remove the caption.

Example:

$showImageCaption = true;