Bug 32794: Expand tests for access method in XLST files
[koha-ffzg.git] / koha-tmpl / opac-tmpl / bootstrap / en / xslt / MARC21slim2OPACResults.xsl
index 9e7a16a..ffd4e26 100644 (file)
                                </xsl:when>
                                <xsl:otherwise>
                     <xsl:attribute name="href">
-                        <xsl:if test="not(contains(marc:subfield[@code='u'],'://'))">
+                        <xsl:if test="not(contains(marc:subfield[@code='u'],'://') or contains(marc:subfield[@code='u'],'mailto:'))">
                             <xsl:choose>
                                 <xsl:when test="@ind1=7">
                                     <xsl:value-of select="marc:subfield[@code='2']"/><xsl:text>://</xsl:text>
                                 </xsl:when>
+                                <xsl:when test="@ind1=0">
+                                    <xsl:text>mailto:</xsl:text>
+                                </xsl:when>
                                 <xsl:when test="@ind1=1">
                                     <xsl:text>ftp://</xsl:text>
                                 </xsl:when>
+                                <xsl:when test="@ind1=2">
+                                    <xsl:text>telnet://</xsl:text>
+                                </xsl:when>
+                                <xsl:when test="@ind1=3">
+                                    <xsl:text>tel:</xsl:text>
+                                </xsl:when>
                                 <xsl:otherwise>
                                     <xsl:text>http://</xsl:text>
                                 </xsl:otherwise>