Permalink
Browse files

Merge pull request #27 from mendhak/master

Ability to pull photos using flickr tags
  • Loading branch information...
2 parents 112e097 + 3f5e39e commit 5b0918843fea3baca2b273f1ef21d27e72be6896 @samdunn samdunn committed Jul 26, 2011
Showing with 8 additions and 3 deletions.
  1. +2 −1 flickr/flickr.html
  2. +6 −2 flickr/js/supersized.flickr.1.1.2.js
View
@@ -56,10 +56,11 @@
slide_captions : 1, //Slide caption (Pull from "title" in slides array)
//Flickr
- source : 3, //1-Set, 2-User, 3-Group
+ source : 3, //1-Set, 2-User, 3-Group, 4-Tags
set : '######', //Flickr set ID (found in URL)
user : '######', //Flickr user ID (http://idgettr.com/)
group : '######', //Flickr group ID (http://idgettr.com/)
+ tags : '###,###', //Comma separated tags
total_slides : 100, //How many pictures to pull (Between 1-500)
image_size : 'z', //Flickr Image Size - t,s,m,z,b (Details: http://www.flickr.com/services/api/misc.urls.html)
@@ -50,10 +50,11 @@
slide_captions : 1, //Slide caption (Pull from "title" in slides array)
//Flickr
- source : 2, //1-Set, 2-User, 3-Group
+ source : 2, //1-Set, 2-User, 3-Group, 4-Tags
set : '###', //Flickr set ID (found in URL)
user : '###', //Flickr user ID (http://idgettr.com/)
group : '###', //Flickr group ID (http://idgettr.com/)
+ tags : '###,###', //Comma separated tags
total_slides : 100, //How many pictures to pull (Between 1-500)
image_size : 'z', //Flickr image Size - t,s,m,z,b (Details: http://www.flickr.com/services/api/misc.urls.html)
slides : [{}], //Initiate slides array
@@ -112,6 +113,9 @@
case 3: //From a Group
var flickrURL = 'http://api.flickr.com/services/rest/?format=json&method=flickr.photos.search&api_key=' + options.api_key + '&group_id=' + options.group + '&per_page=' + options.total_slides + '&jsoncallback=?';
break;
+ case 4: //From tags
+ var flickrURL = 'http://api.flickr.com/services/rest/?format=json&method=flickr.photos.search&api_key=' + options.api_key + '&tags=' + options.tags + '&per_page=' + options.total_slides + '&jsoncallback=?';
+ break;
}
var flickrLoaded = false;
@@ -367,7 +371,7 @@
} //End slideshow options
- }); //End window load
+ }; //End window load
//Keyboard Navigation
if (options.keyboard_nav){

0 comments on commit 5b09188

Please sign in to comment.