When we configure Moss search well, but its default search link is the connection to the document itself, not the link we want, and sometimes what we want is a column of it to be a link, and sometimes we want to show the other column to the user, you can do it by modifying the properties returned in the search results.
1. First to understand what the moss search returned
The Moss search result returns an XML dataset, and what is the XML data format it returns, as follows:
Code
<all_results>
<result>
<id>1</id>
<workid>56859</workid
<rank>851</rank>
<title> District Information Office to integrate the basic government data, promote the sharing of information resources </title>
<AUTHOR&G T; system account </AUTHOR>
<size>5836</size>
<URL>HTTP://172.25.0.185:7001/BMYW/XXB/2009/63 39694771417558327245.html</url>
<urlencoded>http%3a%2f%2f172%2e25%2e0%2e185%3a7001%2fbmyw%2fxxb %2f2009%2f6339694771417558327245% 2ehtml</urlencoded>
<description></description>
< Write>2009/5/21</write>
<sitename>http://172.25.0.185:7001</sitename>
<collapsin Gstatus>0</collapsingstatus>
<HHTitle> Area ;c0> Information </c0> Office consolidate the basic data of government affairs, promote <c0> Information </c0> resource sharing <contentclass>sts_listitem_documentlibrary</contentclass>
<isdocument>1</isdocumen T>
<picturethumbnailurl></picturethumbnailurl>
<imageurl imageurldescription= type results: Document ">/_layouts/images/html16.gif</imageurl>
</result>
<result>
...
</result>
</all_results>
The code above can be used to modify the XSL properties of moss search results by changing the XSL default property of the Moss search core results Web Part to:
Code
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml" version="1.0" encoding="UTF-8" indent="yes"/>
<xsl:template match="/">
<xsl:copy-of select="*"/>
</xsl:template>
</xsl:stylesheet>
When you have finished modifying the HTML source code for the search results, you can find the XML code above. From the above code you can see that the main attributes of the Moss search results are workid,title,url,hhtitle,hhurl and so on.
2. Add metadata attribute Mappings
Because the properties returned by the search results are mapped from metadata attributes, you must select the configuration metadata attribute mappings for the attributes that we want to add to the search results, and for how to configure metadata property mappings, see Bear-study-hard's "MOSS Search Learning Records (v): Searching for a specified range of content in multiple lists using metadata and rules, be careful to start a full crawl instead of adding a crawl, or a new property value that is empty.