Ok, this is starting to get aggravating. I'm having several problems while trying to implement search for the products module. I used the code in the "In the meantime" blog, and search is indexing the products, more or less correctly.
It's been said a number of times that the search engine spiders the page just like any other search engine, but this can't be the case. If I search for Pinot, I get results from the products database where Pinot is in the Product Name, or in a tag that has been applied, or in one of my custom metafields. This is exactly what I want. The second item from the search results is this:
... ... For more information on this wine, please contact us at info@SomeSite.com Barth Pinot Gris 2006 TRIFLB004 3.3 26.99 25.99 150 290 Pinot Gris White Alsace France 2006 ...
Ok, notice in the snippet field, the word Alsace? That doesn't appear anywhere in the product page, yet it's in the index, and in the results. Somehow Search found this, but looking through the index provider code in the products module (from that blog entry), I can't see how it picks that up.
Anyway, I have two very critical issues:
1. How do I get access to each of these indexed metafield properties in the resultset? I can't find information anywhere that tells me what fields are available in the search results, so I can't format the results at all. Can you tell me what fields are available?
2. Even though I set the page title to be the name of the wine, with:
// this finds the control in the single item container.
if (itemContainer.GetType() == typeof(Telerik.Cms.Engine.WebControls.ContentView.SingleItemContainer))
this.Page.Title = contentItem.GetMetaData("Name") as string;
it doesn't show up in the search results. I look at the page source, and the title is set. But in the databinding for the search results, this is blank:
How can I get access to the metafields, and why doesn't the title show up?