Searches with accents (diacritics) fail

Feb 15, 2010 at 11:18 PM

I'm using the PhotosSearch() method to return images of cars which works a treat until you come across a car name that has letters that have accents (diacritics). e.g.  Lamborghini Reventón or Citroën DS

Searching on the Flickr website for those cars (or hitting the search URL directly) returns heaps of photos but when I attempt to retrieve photos using PhotosSearch() I get almost nothing.

This is an abbreviated version of my code (the model name is retrieved from the database, otherwise it's identical). I get the same results whether I use options.Text or options.Tags:

var flickr = new Flickr(ConfigurationManager.AppSettings["FlickrApiKey"]);
var options = new PhotoSearchOptions();
options.TagMode = FlickrNet.TagMode.AllTags;
options.Text = "Lamborghini Reventón";
var photos = flickr.PhotosSearch(options);

The only image this search returns for me is this: ... it has the word Reventón in the description.

I've run the model names through a method to replace diacritics with  (e.g. Lamborghini Revent%C3%B3n) but I still get the same results.

Am I missing something here?

Feb 15, 2010 at 11:22 PM

OK, I just ran that exact code up there and it WORKED goddammit! Please ignore the above post. :(


Feb 16, 2010 at 11:38 AM

OK, thanks for letting me know.