From db7b858af749c6743ed2cadeecacd0a48d83a31d Mon Sep 17 00:00:00 2001 From: Rick Davies Date: Mon, 16 Sep 2013 10:58:16 -0700 Subject: [PATCH 1/2] Added option to choose different img resolutions --- README | 8 ++++++++ index.html | 9 +++++---- js/jquery-flickr-gallery/jquery-flickr-gallery.js | 7 ++++--- 3 files changed, 17 insertions(+), 7 deletions(-) diff --git a/README b/README index e483c73..dd27c7e 100644 --- a/README +++ b/README @@ -8,3 +8,11 @@ A Flickr Set for the plug in interact with. If you need help in setting up a Fl http://www.flickr.com/help/collections +Image resolution info +500x333 - '' +640x427 - 'z' +800x534 - 'c' +1024x683 - 'b' +1600x1067 - 'h' +2048x1365 - 'k' +3888x2592 - 'o' \ No newline at end of file diff --git a/index.html b/index.html index 735e021..25ff42a 100755 --- a/index.html +++ b/index.html @@ -46,10 +46,11 @@ // Replace the setID below with your setID // Get your flickrAPI here: http://www.flickr.com/services/api/misc.api_keys.html $(document).ready(function() { - $('#flickr_div').flickrGallery({ - "flickrSet" : "FLICKR_SET", - "flickrKey" : "FLICKR_API" - }); + $('#flickr_div').flickrGallery({ + "flickrSet" : "FLICKR_SET", + "flickrKey" : "FLICKR_API", + "mainPhotoResolution" : "" + }); }); diff --git a/js/jquery-flickr-gallery/jquery-flickr-gallery.js b/js/jquery-flickr-gallery/jquery-flickr-gallery.js index e9c6e01..42cbf37 100755 --- a/js/jquery-flickr-gallery/jquery-flickr-gallery.js +++ b/js/jquery-flickr-gallery/jquery-flickr-gallery.js @@ -10,7 +10,7 @@ var flickrhelpers = null; (function(jQuery) { jQuery.fn.flickrGallery = function(args) { - + var $element = jQuery(this), // reference to the jQuery version of the current DOM element element = this; // reference to the actual DOM element @@ -42,9 +42,10 @@ var flickrhelpers = null; var length = flickrData.photoset.photo.length; var thumbHTML = ''; - + + var mainPhotoResolution = settings.mainPhotoResolution != null && settings.mainPhotoResolution != '' ? '_'+settings.mainPhotoResolution : ''; for (i=0; i'; settings.imgArray[i] = photoURL; From 8136e7bdb5b10b7135187c734df39b80bfc3a82e Mon Sep 17 00:00:00 2001 From: Rick Davies Date: Mon, 16 Sep 2013 11:01:55 -0700 Subject: [PATCH 2/2] https://github.com/iamjpg/jQuery-Flickr-Gallery-Plug-In/commit/aa831d38f340a50384f18450548b864f18eac4b4 --- js/jquery-flickr-gallery/jquery-flickr-gallery.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/jquery-flickr-gallery/jquery-flickr-gallery.js b/js/jquery-flickr-gallery/jquery-flickr-gallery.js index 42cbf37..33ad173 100755 --- a/js/jquery-flickr-gallery/jquery-flickr-gallery.js +++ b/js/jquery-flickr-gallery/jquery-flickr-gallery.js @@ -178,7 +178,7 @@ var flickrhelpers = null; "imgArray" : [], // Array to hold urls to flickr images "titleArray" : [], // Array to hold image titles if they exist "currentIndex" : 0, // Default image index - "fImg" : null, // For checking if the image jqfobject is loaded. + "fImg" : null // For checking if the image jqfobject is loaded. } // For extending the defaults!