exp:eeflickr:photos_search

This will probably be your most used tag... Return a list of photos matching some criteria. Only photos visible to the calling user will be returned. To return private or semi-private photos, the caller must be authenticated with 'read' permissions, and have permission to view the photos. Unauthenticated calls will only return public photos.

Params

  • user_id: The NSID of the user who's photo to search. If this parameter isn't passed then everybody's public photos will be searched. A value of
  • tags: A comma-delimited list of tags. Photos with one or more of the tags listed will be returned.
  • tag_mode: Either 'any' for an OR combination of tags, or 'all' for an AND combination. Defaults to 'any' if not specified.
  • text: A free text search. Photos who's title, description or tags contain the text will be returned.
  • min_upload_date: Minimum upload date. Photos with an upload date greater than or equal to this value will be returned. The date should be in the form of a unix timestamp.
  • max_upload_date : Maximum upload date. Photos with an upload date less than or equal to this value will be returned. The date should be in the form of a unix timestamp.
  • min_taken_date: Minimum taken date. Photos with an taken date greater than or equal to this value will be returned. The date should be in the form of a mysql datetime.
  • max_taken_date: Maximum taken date. Photos with an taken date less than or equal to this value will be returned. The date should be in the form of a mysql datetime.
  • license : The license id for photos (for possible values see the flickr.photos.licenses.getInfo method). Multiple licenses may be comma-separated.
  • sort: The order in which to sort returned photos. Deafults to date-posted-desc. The possible values are: date-posted-asc, date-posted-desc, date-taken-asc, date-taken-desc, interestingness-desc, interestingness-asc, and relevance.
  • privacy_filter: Return photos only matching a certain privacy level. This only applies when making an authenticated call to view photos you own. Valid values are:
    • 1 public photos
    • 2 private photos visible to friends
    • 3 private photos visible to family
    • 4 private photos visible to friends & family
    • 5 completely private photos
  • bbox: A comma-delimited list of 4 values defining the Bounding Box of the area that will be searched. The 4 values represent the bottom-left corner of the box and the top-right corner, minimum_longitude, minimum_latitude, maximum_longitude, maximum_latitude.
  • accuracy: Recorded accuracy level of the location information. Current range is 1-16 :
  • safe_search: (Please note: Un-authed calls can only see Safe content.)
    • 1 for safe.
    • 2 for moderate.
    • 3 for restricted.
  • content_type:
    • 1 for photos only.
    • 2 for screenshots only.
    • 3 for 'other' only.
    • 4 for photos and screenshots.
    • 5 for screenshots and 'other'.
    • 6 for photos and 'other'.
    • 7 for photos, screenshots, and 'other' (all).
  • machine_tags: Aside from passing in a fully formed machine tag, there is a special syntax for searching on specific properties :
    • Find photos using the 'dc' namespace : 'machine_tags' => 'dc:'
    • Find photos with a title in the 'dc' namespace : 'machine_tags' => 'dc:title='
    • Find photos titled 'mr. camera' in the 'dc' namespace : 'machine_tags' => 'dc:title=\'mr. camera\'
    • Find photos whose value is 'mr. camera' : 'machine_tags' => '*:*=\'mr. camera\''
    • Find photos that have a title, in any namespace : 'machine_tags' => '*:title='
    • Find photos that have a title, in any namespace, whose value is 'mr. camera' : 'machine_tags' => '*:title=\'mr. camera\''
    • Find photos, in the 'dc' namespace whose value is 'mr. camera' : 'machine_tags' => 'dc:*=\'mr. camera\''
  • machine_tag_mode: Either 'any' for an OR combination of tags, or 'all' for an AND combination. Defaults to 'any' if not specified.
  • group_id : The id of a group who's pool to search. If specified, only matching photos posted to the group's pool will be returned.
  • extras: A comma-delimited list of extra information to fetch for each returned record. Currently supported fields are: license,date_upload,date_taken,owner_name,icon_server,original_format,last_update,geo,tags,machine_tags,o_dims,views,media.
  • per_page: Number of photos to return per page. If this argument is omitted, it defaults to 100. The maximum allowed value is 500.
  • page: The page of results to return. If this argument is omitted, it defaults to 1.
  • media: Filter results by media type. Possible values are all (default), photos or videos
  • sign: "yes" set to yes if you are requesting your (private,friends,family) data if this is not set only public data is returned for this tag. (about Authentication)
  • refresh: (cache time in minutes) this overrides the default time eeFlickr stores Flickr API data before requesting new data from Flickr

Full Tag

{exp:eeflickr:photos_search  user_id="47282007@N00" page="page1" per_page="30" }
    {eeflickr
:photos_search_loop} 
        {id}
        {owner}
        {secret}
        {server}
        {farm}
        {title}
        {ispublic}
        {isfriend}
        {isfamily}
        {license}
        {dateupload}
        {datetaken}
        {datetakengranularity}
        {ownername}
        {iconserver}
        {iconfarm}
        {originalsecret}
        {originalformat}
        {lastupdate}
        {latitude}
        {longitude}
        {accuracy}
        {tags}
        {machine_tags}
        {media}
        {views}
        {o_width}
        {o_height}
        {count}
{if no_results}
  some text here
{
/if}
    {
/eeflickr:photos_search_loop} 
    {eeflickr
:photos_search_paging} 
        page    
{page}
        pages   
{pages}
        perpage 
{perpage}
        total   
{total}
    {
/eeflickr:photos_search_paging}
{
/exp:eeflickr:photos_search} 


Sample Usage

in the below example we return 16 of my most recent photos and use {segment_4} as our paging variable.
The pagination links are created by placing the {exp:eeflickr:paginate} tag inside the {eeflickr:photos_search_paging} pair

     

Image List example:

{exp:eeflickr:photos_search  user_id="47282007@N00" page="{segment_4}" per_page="16"}
                
    {eeflickr
:photos_search_loop}  
        
<div style="float:left; text-align:center; height:80px; width:80px; overflow:hidden;">
          <
a href="/picture/{id}/"><img src="http://farm{farm}.static.flickr.com/{server}/{id}_{secret}_s.jpg" alt="{title}" /></a>
        </
div>
    
{/eeflickr:photos_search_loop}
    
    {eeflickr
:photos_search_paging} 
    
<div style="clear:both;"></div>
               
{exp:eeflickr:paginate page="{page}" pages="{pages}" perpage="{perpage}" total="{total}" max_links="2"}
                    Page {current_page} of {total_pages} pages {if current_page 
!= "1"}{first_page_link} <a href="{prev_page_url}">Previous</a>{/if}
                    {pagination_links}
                    {if current_page 
!= total_pages}<a href="{next_page_url}">Next</a{last_page_link}{/if}
                {
/exp:eeflickr:paginate}
    {
/eeflickr:photos_search_paging}
    
{
/exp:eeflickr:photos_search}

Video Example
:

{exp:eeflickr:photos_search  user_id="69005233@N00" media="video" sort="interestingness-desc" page="{segment_4}" per_page="3"}
    {eeflickr
:photos_search_loop}
    
<embed id="stewart_swf{id}" width="180" height="135" flashvars="intl_lang=en-us&div_id=stewart_swf{id}_div&flickr_notracking=true&flickr_target=_self&flickr_h=135&flickr_w=180&flickr_no_logo=false&onsite=false&flickr_noAutoPlay=true&photo_secret={secret}&photo_id={id}&flickr_doSmall=true" allowscriptaccess="always" allowfullscreen="true" quality="high" bgcolor="#000000" base="." name="stewart_swf2372328500" style="visibility: visible;" src="http://www.flickr.com/apps/video/stewart.swf.v49235" type="application/x-shockwave-flash"/>
    
{/eeflickr:photos_search_loop}
    
<div style="clear:both;"></div>
    <
div id="pagination">
       
{eeflickr:photos_search_paging}
               {exp
:eeflickr:paginate page="{page}" pages="{pages}" perpage="{perpage}" total="{total}" max_links="2"}
                    Page {current_page} of {total_pages} pages {if current_page 
!= "1"}{first_page_link} <a href="{prev_page_url}">Previous</a>{/if}
                    {pagination_links}
                    {if current_page 
!= total_pages}<a href="{next_page_url}">Next</a{last_page_link}{/if}
                {
/exp:eeflickr:paginate}
       {
/eeflickr:photos_search_paging}
     
</div>
{/exp:eeflickr:photos_search} 


     



Sample Above Will Output

Video Sample Above Will Output