After investigating the issue, I found out that client had deleted the “Search Box” web part from the search results page as they don’t want user to search again from the results page and you know what? “Object expected” error started popping up as soon as client removed the “Search Box” web part.
The reason is as follows:
- SharePoint records the user clicks on search results link.
- SendSoap function is defined in Search.js file located at /_layouts/ 1033 folder.
- Search Box web part includes this file on search results page.
- Search Core Results web part assumes that Search.js file will always be available and attaches the call to SendSoap on Search Result links.
- Deleting the Search Box web part will remove the reference to Search.js and as a result you will start getting the Object expected error whenever you click any link on results page.
- If you really don’t want Search Box web part on your search result page then mark it hidden instead of deleting it. In this way, you will have the reference of Search.js in your search page. OR
- Include the reference to Search.js manually either by CEWP or any other means, you feel appropriate.