It should be possible to create links between records for MARC21 fields 780 and 785. The referenced record id should be saved in the $w subfield.
Nothing to do here actually - 780 and 785 already allow to link by $w. <xsl:choose> <xsl:when test="$UseControlNumber = '1' and marc:subfield[@code='w']"> <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=Control-number:<xsl:call-template name="extractControlNumber"><xsl:with-param name="subfieldW" select="marc:subfield[@code='w']"/></xsl:call-template></xsl:attribute> <xsl:value-of select="$f785"/> </a> </xsl:when> <xsl:otherwise> <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=ti,phr:<xsl:value-of select="str:encode-uri(translate($f785, '()', ''), true())"/></xsl:attribute> <xsl:value-of select="$f785"/> </a> </xsl:otherwise> </xsl:choose>