This project has moved. For the latest updates, please go here.

How to perform "any of these words" search through the API?

Topics: User Forum
Oct 29, 2009 at 4:14 PM

I noticed that de Flickr API searches with "all of these words" by default.

How can I perform a text search with the "any of these words" option throught the Flickr API?

Used code:

Flickr flickr = new Flickr("dev api key");
PhotoSearchOptions searchOptions = new PhotoSearchOptions();
searchOptions.SafeSearch = SafetyLevel.Safe;
searchOptions.Text = "list of space seperated words";
searchOptions.SortOrder = PhotoSearchSortOrder.Relevance;
Photos page1ofresults = flickr.PhotosSearch(searchOptions);
Oct 29, 2009 at 4:20 PM
Edited Oct 29, 2009 at 4:21 PM
The following seems to work: 

searchOptions.Text = "microsoft OR french OR colorful";

If you look carefully at the URL for the Flickr web site search then this is exactly what they do.
Oct 29, 2009 at 7:36 PM

Indead, this works. Thank you.