Search code examples
sharepointsharepoint-onlinesharepoint-search

Get search scope and redirect to external search service in Sharepoint


I would like to have an link/button at the end of search results in Sharepoint Online. This button/link should grab the current search keyword and redirect to another search engine that is external to Sharepoint. E.g. Clicking on the link will redirect from "https://contoso.sharepoint.com/_layouts/15/search.aspx/siteall?q=hello" to "https://www.google.com/search?q=hello". I have tried to add JS directly to search box search event but the requirement is to display the search result in the same page and then give user option to "Expand" the search to another site.


Solution

  • There has not been a reply so I am writing what I ended up doing. The Expand search option to another sharepoint page which on rendering will redirect to our custom search engine. ** Note: this will result in redirection when search is performed from defualt page of the sharepoint site.