I am trying to change the aspx file icon from default icon to customized icon. I edited the xsl of the results.aspx page “fetched properties” for this section. I wanted to make sure that LegalDoc16.gif icons are displayed for the items who has “LegalDocument” content type. Please let me know if I dont have to syntaxed properly configured. I can do a search like ContentType:”legaldocument” and I get all the documents. so I know contenttype metadata property is being pulled. Please suggest.
<div class="srch-Icon" id="{concat($currentId,'_Icon')}">
<xsl:choose>
<xsl:when test="string(ContentType)='LegalDocument'">
<img align="absmiddle" src="_layouts/images/LegalDoc16.gif" border="0" alt="{imageurl/@imageurldescription}" />
</xsl:when>
<xsl:otherwise>
<img align="absmiddle" src="{imageurl}" border="0" alt="{imageurl/@imageurldescription}" />
</xsl:otherwise>
</xsl:choose>
</div>
Everthing was fine. All I had to do before running the powershell, go to the document library and add a file based on Linked to Document (and delete the test upload file). After that it worked.