Flickr Group Pool Photo Search By Tag
The tutorial shows you how to search group pool photos on Flickr using a tag. You may want to use this feature when you a running a Flickr Group and want to be fetch a selection of photos based on the tag.
For tagging to be manageable I would advise the group moderator to put together some guidelines for tagging so the tags are consistent. For example, it is not particularly useful if say you have photos of a local church and some people tag it variously as “St Leonards”, “Saint Leonards”, “St Leonards Church”, “Saint Leonards Church”, “Saint”, “Leornards” and “Church”. In this case we have 7 possible tags for the same subject. If the group moderator comes up with a sensible list of suggestions for tags then the problem is mitigated. In any case group members can add tags to other people’s photos so you can ensure that a photos will have the correct tag among the others but a good tagging strategy will reduce clutter and a proliferation of tags.
The command is straightforward
[code]slickr-flickr search="groups" id="the group id" tag="the tag"[/code]
Requirements/ Pre-requisites
You need to have fetched your Flickr API key and saved it in Slickr Flickr Admin settings.
You need to do this because Slickr Flickr uses the Flickr API to search by group photos by tag.
Restrictions
Please note that you can only specify a single tag: multiple tags are not supported by the Flickr API group photo search
You can only access Public Flickr groups: private groups are not accessible
Flickr Video Tutorial for Searching Group Photos by Tag
From Slickr Flickr version 1.22 onwards you can select group pool photos by tag.
Example of Searching for Cheese
Here I am searching the “Cheese” group for the latest photos
[code]slickr-flickr search="groups" id="90309711@N00" flickr_link="on"[/code]
Example of Search For French Cheese
Here I am searching the “Cheese” group for recent photos tagged with France
[code]slickr-flickr search="groups" id="90309711@N00" tag="france" flickr_link="on"[/code]
Russell says
Hi Peter,
Slickr Flickr does not support a search by both tag and photoset – but it could be added. The code could either make two fetches one for the set; and another for the tag and then return photos that appears in both search. Or it could fetch all the photos in a set and then filter out any than did not have the desired tag(s).
Right now the workaround would be to tag everything in the set with a tag that is the same as the setid and then a normal multi-tag search:
For example, [slickr-flickr items="50" tagmode="all" tag="zzz,mysethere" type="gallery"]
However, this is not really using tags in the way Flickr would want you to use them.
Peter says
I was looking for a way that a web user could look into my flickr through wordpress using your plugin and do searches.
lets say I want to use
[slickr-flickr search="sets" set="mysethere" items="50" tag="zzz" type="gallery" ]
but I want the visitor to either supply the tag or choose it from a drop down that i supply? any thoughts on how that could be accomplished with free or pro version
Russell says
Hi Dave,
You could have a “Cheese” post with the command slickr-flickr tag=”cheese” type=”gallery”. The link would then just be a link to the post.
If you want to parameterize you can have a search page with a input form variable, “s”, and on the search results page you need a snippet of php that uses “s” to search for photos.
Something like this:
do_shortcode(sprintf('[slickr-flickr tag="%1$s" type="gallery"]',$_REQUEST['s']));
This would give a set of photos that are tagged with the search criteria entered on the search form.
Regards
Russell
dave algeo says
Russell this is excellent and I’ll be sure to try it.
But I’m struggling with one last hurdle. How to make the shortcode into a link, so I could have the word cheese on my site, which only when clicked on would then display the results found for ‘cheese’. (target self or searchpage).
A prod in the right direction would be greatly appreciated as I’ve reached a dead end.
Kind regards,
Dave.