Thursday, April 24, 2014

The 100% way of getting your custom properties to show in your Display Templates

I’ve been meaning to blog this for some time, so here goes.

The issue is that you create a custom display template, and in that template you add a custom managed property which you want displayed like I have here with LinkOfficeChild.

<mso:HtmlDesignAssociated msdt:dt="string">1</mso:HtmlDesignAssociated>
<mso:ManagedPropertyMapping msdt:dt="string">'Title':'Title','LinkOfficeChild':'LinkOfficeChild'</mso:ManagedPropertyMapping>
<mso:HtmlDesignConversionSucceeded msdt:dt="string">True</mso:HtmlDesignConversionSucceeded>

The next step you do is create a new Result Type, set your trigger conditions and choose to use your custom display template.

image



You are even wise to read the Note at then end, go back to the Result Types page, click the update button to get the awaited message that everything is now OK and should work.

image

Then you head over to your search page and you get NOTHING!

image

So what do you do to resolve this? Go back to the Result Source and check Optimize for frequent use.

image

…and your values will show!

image