Searching smugmfor captions, titles, etc.
rutt
Registered Users Posts: 6,511 Major grins
I'd like visitors to my smugmug site/categories/subcategories/galleries to be able to search them for captions, filenames, &etc.
For example, suppose I have taken pictures at a marathon and through a lot of work managed to caption the pictures with participant names. It would be great to be able to search the shots for the pictures of someone one knows or onesself.
For example, suppose I have taken pictures at a marathon and through a lot of work managed to caption the pictures with participant names. It would be great to be able to search the shots for the pictures of someone one knows or onesself.
If not now, when?
0
Comments
The default behavior is to search just the person's galleries whose pages you're viewing. It will search gallery names and descriptions and list galleries it found separately, then search photo captions and list any it finds.
If you embed hidden keywords in your photos via the IPTC keyword fields, it will find them. We don't advertise that too broadly because merchants could potentially use them to spam our search results. But they were put there for pro photographers and quite a few of them use IPTC data for content management or so people can search on their race bib # in events, for example.
Your cobranding has removed the search field, but you can add this code to your cobranding to place it wherever you want on the page:
<form method="get" action="/search/index.mg">
<input type="text" name="searchWords" />
<input type="hidden" name="searchType" value="InUser" />
<input type="hidden" name="NickName" value="rutt" />
<input type="submit" value="Search Galleries" />
</form>
Here's an example of a photographer who placed it in his footer: http://williams.smugmug.com .
One proviso is global search is an and search, whereas that search box is an or search. Different photographers have views on which it should be, so perhaps we'll make it selectable in the future.
I hope this helps.
Thanks,
Baldy
I have enabled "show filenames" for these galleries (I wish this could be the default!) But when I use the search field I inserted (as you suggested), it doesn't find the filenames. For example searching for "img_0756" finds nothing, yet here is the photo. I also tried searching for "img_0756.jpg" and found nothing.
Perhaps I'm missing something in my search fileld html?
Under certain circumstances, the filename becomes the caption, such as a filename like Lance_Wins_the_Tour.jpg, which we parse into a caption called Lance Wins the Tour.
We received quite a lot of feedback that one of the pet peeves users experience is seeing numbers that cameras assign to the files being displayed as captions. It's quite a hot button for them. That's why it's off by default.
If your content management software places the filename into the IPTC caption field, however, it would be displayed by default and would be found in the search engine. The reason is we look for an IPTC caption and assume the customer wants it displayed.
We are going to make gallery defaults customizable in the future but a few really big projects have to be checked off the list first, unfortunately.
Thanks,
Baldy
I used the search script on my site. It works sometimes, and then it doesn't. I u/l pictures with the people's last name (Jones 0001), and a number. The search will not find the names.
I u/l last names before... a while back, and those names came up in the search. Why is the search not always working? Is there something I'm doing wrong? It should search file names and captions, right?
Please help...
Erik
1. He extracts captions, IPTC keywords, and parsed filenames for each photo and places them in the search index. Parsed filenames means he removes non-alphanumeric characters such as _ - & . , etc.
If you upload a file with a caption like james_bond_007.jpg, you can find it using search for james or bond or 007, but not for james_bond_007. The filename will be displayed, however, as james_bond_007 (we strip off the .jpg for display).
Let's suppose you had entered IPTC keywords of Sean Connery before uploading the photo. And you then entered a caption of Rutt. Users would find this photo by searching for Rutt, Sean, Connery, James, Bond, 007, or any combination.
You might wonder why we didn't make it either/or, meaning if they had the show filenames option on, just search for filenames, whereas if they had it off, just search for captions. The answer is we noticed how many galleries have show filenames on but some of the photos inside are captioned, but not all. Another is we felt we should err on the side of finding it. And a thrid is it was much easier.
2. Results are now ranked much more finely, based both on how many times the word appears, as well as it's relative "weight" compared to the rest of the words in it's caption/title/etc. Example:
Search for "Macaskill":
"MacAskill MacAskill MacAskill" shows up before
"MacAskill" which shows up before
"MacAskill Johnson" which shows up before
"MacAskill clan goes to see the Gladigator"
Erik reported an issue where not all of his images are being found and we're currently investigating. Strangely, one that was being found has DCP 1.0 in the IPTC caption field, and two that aren't being found are blank there.
Thanks,
Baldy