Include URL rewrites in search results - General Discussions - General Discussions - Progress Community
 General Discussions

Include URL rewrites in search results

  • Include URL rewrites in search results
  • I'm looking into the possibility of using URL rewrites. Below is an example of the URL rewrite I am using.

    <rule name="Topic Rewrite" stopProcessing="true">
     <match url="^topics/([^$]+)" />
    <add input="URL" negate="true" pattern="action/edit" />
     <action type="Rewrite" url="topics?id=R:1" />

    Now when using the Sitefinity search results widget, the URL rewrites do not appear in the search results. How can I go about including them in the search results?
  • Hi Sean,

    Please note that Sitefinity uses IContentLocatableView interface implemented on the out of the box content widgets in order to track their locations on different pages. This interface powers the Search indexing and the correct resolving of the links in it. It tells Sitefinity where the specified type of content is placed on the site and properly displays the links in the search results. So, the indexed items will appear in the search results with the links to the pages where they are rendered in Sitefinity.

    What i assume is that when the item is clicked then the rewrite rule you have implemented should be applied and the user should be redirected to this url.

    Sabrie Nedzhip
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Sitefinity CMS Ideas&Feedback Portal and vote to affect the priority of the items