Saturday, November 29, 2014

Go Home and Go Back functionlaity on SharePoint Search Results Page

Hi,

There was a requirement of Go Back and Go Home functionality on the SharePoint search  results page.

Because once user is redirected to share point search results page user should have certain option to go back to previous page/going back to home page.

To achieve this I have added a content editor web part on search results page through below navigation.

Site Actions->Edit Page->Click on Add a web part->Media and Content->Content Editor web part->Click here to add new content.

Post this clicking on Edit HTML Source on the ribbon.

I have pasted the below html to achieve the functionality
First we have used history.go(-1) in ‘Go Back’ functionality.

But problem with this is it works only in IE browser, didn't work in chrome/Firefox browser.

No comments:

Post a Comment