Leveraging Search Web Parts and Display Templates

One of my main focuses the past 4-5 years has been leveraging the Search Infrastructure to help deliver dynamic content to portals and Intranets.  In previous versions of SharePoint I leaned heavily on the underlying APIs to deliver custom solutions.  This was both because the underlying APIs allowed more precise querying and because it gave me full control on what was rendered to the user.

With SharePoint 2013 the Search related web parts went through a pretty major renovation, especially for on-premises customers that have Enterprise CALs.  A series of web parts were created, with a full featured query builder that allows you to create and test your queries through a web interface.  Where the results were previously rendered in XSLT, the new method utilizes regular html and javascript to create the output markup which is then injected into the page.  The overall rendering of the pages is much more dynamic, with support to display each item differently based on the type of content it is.  The potential is limitless. 

I intend for this post to be a bit of a primer on the high level topics.  I’ll be coming out with some specific task-driven follow up posts over the next few weeks that expand on these concepts and get into some examples of things that can be done through these new features. 

Dynamic Content using Search Web Parts

For those that haven’t caught my session Dynamic Content using SharePoint Search here is a brief overview.

The web parts themselves are broken into the following categories:

  • Content Rollup (Enterprise Feature)
  • Search-Driven Content (Enterprise Feature)
  • Search

 

Within the Content Rollup category resides the Content Search web part.  This is a great replacement for the Content Query Web Part (CQWP) available in past versions of SharePoint.  Unlike the CQWP, this utilizes the search service so it can pull matching results from anywhere in your farm, which means you are not limited to the current site collection. 

The web part also supports new, previously unavailable display options including the ability to show the item as a slideshow. 

The Search-Driven Content category contains a series of web parts that are all based on the Content Search web part, with a pre-set query to help you get started.  This includes results that display specific types of content like the Videos, Web Pages, Wiki Pages, Pictures, Pages, and then also results that rely on the analytics features to deliver results pertaining to Popular Items, Recently Changed Items, and Recommended Items.  The pre-configured queries are a great start, and using the query builder form you can dial in the specific results you are looking to display. 

Search Display Templates

All of the search web parts, including the standard Search Results web part that is available in all versions of SharePoint Server as well as the SharePoint Online service within Office 365, then offer the ability to change how your results are rendered using the Search Display Templates.  This is where the real power of the new changes come into play since we can now change how items are rendered by editing the html and javascript in the display templates. 

The display templates are stored in the Master Page Gallery for each site collection.  You can find them by browsing to Site Settings, and clicking the Master pages and page layouts link under the Web Designer Galleries group.  From within the gallery, browse into the display templates directory, and then into the Search directory for search specific display templates. 

A good reference for the included display templates is available here on the TechNet/MSDN website:  http://technet.microsoft.com/en-us/library/jj944947(v=office.15).aspx

Here is a good overview of how to work with the display templates:  http://msdn.microsoft.com/en-us/library/office/jj945138(v=office.15).aspx

SPS Bermuda Wrap-up

I think everyone had a fantastic time at the inaugural SharePoint and .NET Saturday Bermuda event.  I’m honored to have been able to participate.  The hospitality on the island was fantastic, and while the event was small, there was good participation in the sessions.  I hope everyone got a lot out of the day.

I’ve uploaded my deck to slide share so it is available below.

 

I look forward to future events!

SharePoint Saturday Atlanta Wrap-up

SharePoint Saturday Atlanta was a great success again this year with a record turnout that included many eager participants. 

Thanks to all of the attendees that attended my sessions.  Here is the supporting content. 

Displaying Dynamic Content With Search

 

Developer’s Introduction to the Social APIs

Code Examples:

SPS Atlanta Sessions on Search and Social

I’m excited to announce that I have had two sessions selected for the SPS Atlanta event on Saturday June 8th.  The past few years the organizers have established this event as one of the premiere events in the south east.

The first session is an End User focused session titled Using Search for Dynamic Content.

This session is geared towards site owners and power users and will provide an overview of the search web parts available out of the box in SharePoint 2010 and 2013 and show how they can be used to display dynamic, search driven content on your sites.  We will also do an overview of the Keyword Query Language allowing you to leverage the features to display dynamic content on your sites.

 

The second session is a Developer focused session titled Introduction to SharePoint’s Social APIs

SharePoint 2010 and 2013 offers a rich set of social capabilities that are built into the platform.  Those capabilities are available to developers through a variety of APIs so that they can be extended or leveraged in your other customizations and applications.  This session will run through the various client, server, and REST APIs available to developers.

 

Hope to see a full house!

SPSEvents NYC and Social API Presentation

I’m excited to announce that my session Introduction to SharePoint’s Social APIs has been selected for the SPS Events NYC event on Saturday July 27th.  This has been a fantastic event the past few years, and I’m sure this year will be no different. 

Here is the abstract for my session:

SharePoint 2010 and 2013 offers a rich set of social capabilities that are built into the platform.  Those capabilities are available to developers through a variety of APIs so that they can be extended or leveraged in your other customizations and applications.  This session will run through the various client, server, and REST APIs available to developers.

 

We will take a close look at the APIs themselves, work through a couple of common and not so common example of leveraging those APIs, and then talk about things like performance and best practices.

If you are in the area, stop by and say hello!

Commentary on Purpose Based Licensing

Dan Holme recently had an interesting piece of commentary in the SharePoint Pro magazine titled It’s Time to Break Up the SharePoint Brand in which he advocated breaking the product into purpose based bundles instead of the behemoth platform it is now.  I agree with much of what Dan wrote, including his two main points that it is not a single purpose platform and operates more like a modern OS. 

As I consider the points though, and my own experience evangelizing the platform with customers large and small, I would say that there is already serious confusion about the licensing.  As Microsoft attempts to transform itself to a services based company, I would actually recommend a different sort of licensing move that is even more radical.  When buying server based applications like SharePoint, there should be no need to also individually license the pre-requisite dependency technologies; specifically Windows Server and SQL Server.  These are needed to run the system, so if a customer has a six server farm and busy six licenses of SharePoint Server, then they also require six licenses for Windows Server as well as at least one SQL Server license.  As the number of SharePoint licenses increase, so would the associated Windows and SQL licenses. 

While I think this move makes great sense for customers I am not holding my breadth that Microsoft will make this move any time soon.  I think the biggest reason is the confusion of how to then map revenue back to the other divisions such as the core server OS group, and the database group, but really there should be a set percentage that they can agree on.  I believe that this service or purpose based approach would simplify things quite a bit and should also apply to the other server applications like Exchange, Systems Center, etc.  Of course there will still be a need for stand alone Windows Servers for traditional server things like AD, DNS, Web Sites.

As the move to the cloud continues to evolve this may become more of a moot point for many, but it is unlikely that even half of customers will be running all of their applications primarily in the cloud in the next five years.

%d bloggers like this: