More in this section

Forums / Developing with Sitefinity / Search document library

Search document library

8 posts, 0 answered
  1. GV
    GV avatar
    33 posts
    Registered:
    11 Sep 2009
    24 Feb 2010
    Link to this post
    Hi,

    Thank you for the excellent support you provide. Here is my question.

    How can I search images and documents module? What I was doing is added a custom library to the Images and document module. Then I added 2 new meta fields to store additional data like thumbnail, publication date. Its all working well.
    I'm going to have huge number of these documents in my website. So, instead of displaying all the documents using downloadlist control, I want to provide a search facility. The search need not search the actual documents (i.e. the content inside the document, even though its nice have this feature) , but it has to search on meta data like description, title, publication date etc. Can you guide me on this?

    Thanks & regards
    GV
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    24 Feb 2010
    Link to this post
    Hi GV,

    You need to implement custom index provider, take a look at Sample Products Module or implement a public control that uses ContentFilterBuilder and you are filtering list of items.

    Kind regards,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  3. GV
    GV avatar
    33 posts
    Registered:
    11 Sep 2009
    02 Mar 2010
    Link to this post
    Hi,
    Thanks for the reply. I implemented custom index provider to search across all publications and is working fine with built-in search results control. However  I want to display additional metadata (thumbnial, publicationdate) that is associated with publications in the SearchResults page. Do I need to create my own search results control or is there any easier way for this?

    One more question is do I need to index the metadata as well in GetContentToIndex() method in the Custom provider class?

    Thanks & regards
    GV
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    02 Mar 2010
    Link to this post
    Hello GV,

    If you are inheriting from ContentIndexProvider the metakeys should be added to the snippet of a SearchResult item. Otherwise you have to add all metakeys in a list in Initialize method of your provider and use the metakeys as parameter of ContentIndexerInfo.

    protected virtual IIndexerInfo GetIndexerInfo(string path, IContent content, CultureInfo cult)
    {
    return new ContentIndexerInfo(path, content, this.MetaFields, cult);                                                                                                                         }


    All the best,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  5. GV
    GV avatar
    33 posts
    Registered:
    11 Sep 2009
    02 Mar 2010
    Link to this post
    Hi Ivan,
    Thanks for the quick reply. I added all the metakeys to the CustomIndexerInfo. However I don't want these metakeys to be appended to snippet, instead I want to display them on their own. I want my search result page something like this.
    <table>
    <tr>
    <td>Thumbnail</td>
    <td> Description</td>
    <td>Publicationdate </td>
    <td>Download</td>
    </tr>
    </table>
    Can you give me some inputs on this?

    Thanks & regards
    GV
  6. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    02 Mar 2010
    Link to this post
    Hi GV,

    If the metakeys are not in the snippet of an ResultItem you need to get each item and its data when performing a search. More information at Get artilcle ID

    Best wishes,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  7. GV
    GV avatar
    33 posts
    Registered:
    11 Sep 2009
    02 Mar 2010
    Link to this post
    Hi Ivan,
    That worked, finally my publications search working perfectly. Thank you very much for the supprt

    Thanks & regards
    GV
  8. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    02 Mar 2010
    Link to this post
    Hi GV,

    Glad to hear the everything is working file.

    Greetings,
    Ivan Dimitrov
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Register for webinar
8 posts, 0 answered