Configuring hover panel with custom display tempalte
In this one project there was a requirement to change the search result, we had to add some fields to represent the summary of the record for result of type document and as you might know that you can almost do anything with display templates. We created a display template to show those summary fields. Now, as you know SharePoint has different display templates for different types of documents, like there is a separate display template for Word, PowerPoint, PDF etc. Each of these display templates has a HoverPanel display template associated with them. So, our requirement was to display the same set of summary fields regardless of the document type, and also to have hover over functionality intact. In the normal display template the hover URL is specified and glued with the display template with the following set of lines, var hoverUrl = "~sitecollection/_catalogs/masterpage/Display Templates/Search/Item_KH_WebPage_HoverPanel.js"; ...