Lines 34-43
Link Here
|
34 |
</xsl:variable> |
34 |
</xsl:variable> |
35 |
<xsl:variable name="DisplayOPACiconsXSLT" select="marc:sysprefs/marc:syspref[@name='DisplayOPACiconsXSLT']"/> |
35 |
<xsl:variable name="DisplayOPACiconsXSLT" select="marc:sysprefs/marc:syspref[@name='DisplayOPACiconsXSLT']"/> |
36 |
<xsl:variable name="theme" select="marc:sysprefs/marc:syspref[@name='opacthemes']"/> |
36 |
<xsl:variable name="theme" select="marc:sysprefs/marc:syspref[@name='opacthemes']"/> |
37 |
|
37 |
<xsl:variable name="OPACURLOpenInNewWindow" select="marc:sysprefs/marc:syspref[@name='OPACURLOpenInNewWindow']"/> |
|
|
38 |
<xsl:variable name="URLLinkText" select="marc:sysprefs/marc:syspref[@name='URLLinkText']"/> |
39 |
<xsl:variable name="Show856uAsImage" select="marc:sysprefs/marc:syspref[@name='OPACDisplay856uAsImage']"/> |
40 |
<xsl:variable name="OPACTrackClicks" select="marc:sysprefs/marc:syspref[@name='TrackClicks']"/> |
38 |
<xsl:variable name="leader" select="marc:leader"/> |
41 |
<xsl:variable name="leader" select="marc:leader"/> |
39 |
<xsl:variable name="leader6" select="substring($leader,7,1)"/> |
42 |
<xsl:variable name="leader6" select="substring($leader,7,1)"/> |
40 |
<xsl:variable name="leader7" select="substring($leader,8,1)"/> |
43 |
<xsl:variable name="leader7" select="substring($leader,8,1)"/> |
|
|
44 |
<xsl:variable name="biblionumber" select="marc:datafield[@tag=999]/marc:subfield[@code='c']"/> |
41 |
<xsl:variable name="controlField008" select="marc:controlfield[@tag=008]"/> |
45 |
<xsl:variable name="controlField008" select="marc:controlfield[@tag=008]"/> |
42 |
<xsl:variable name="field019b" select="marc:datafield[@tag=019]/marc:subfield[@code='b']"/> |
46 |
<xsl:variable name="field019b" select="marc:datafield[@tag=019]/marc:subfield[@code='b']"/> |
43 |
<xsl:variable name="typeOf008"> |
47 |
<xsl:variable name="typeOf008"> |
Lines 476-498
Link Here
|
476 |
</span> |
480 |
</span> |
477 |
</xsl:if> |
481 |
</xsl:if> |
478 |
|
482 |
|
|
|
483 |
<!-- Image processing code added here, takes precedence over text links including y3z text --> |
479 |
<xsl:if test="marc:datafield[@tag=856]"> |
484 |
<xsl:if test="marc:datafield[@tag=856]"> |
480 |
<span class="results_summary"><span class="label">Nettbasert ressurs: </span> |
485 |
<span class="results_summary online_resources"><span class="label">Online resources: </span> |
481 |
<xsl:for-each select="marc:datafield[@tag=856]"> |
486 |
<xsl:for-each select="marc:datafield[@tag=856]"> |
482 |
<a><xsl:attribute name="href"><xsl:value-of select="marc:subfield[@code='u']"/></xsl:attribute> |
487 |
<xsl:variable name="SubqText"><xsl:value-of select="marc:subfield[@code='q']"/></xsl:variable> |
483 |
<xsl:choose> |
488 |
<a property="url"> |
|
|
489 |
<xsl:choose> |
490 |
<xsl:when test="$OPACTrackClicks='track'"> |
491 |
<xsl:attribute name="href">/cgi-bin/koha/tracklinks.pl?uri=<xsl:value-of select="marc:subfield[@code='u']"/>;biblionumber=<xsl:value-of select="$biblionumber"/></xsl:attribute> |
492 |
</xsl:when> |
493 |
<xsl:when test="$OPACTrackClicks='anonymous'"> |
494 |
<xsl:attribute name="href">/cgi-bin/koha/tracklinks.pl?uri=<xsl:value-of select="marc:subfield[@code='u']"/>;biblionumber=<xsl:value-of select="$biblionumber"/></xsl:attribute> |
495 |
</xsl:when> |
496 |
<xsl:otherwise> |
497 |
<xsl:attribute name="href"><xsl:value-of select="marc:subfield[@code='u']"/></xsl:attribute> |
498 |
</xsl:otherwise> |
499 |
</xsl:choose> |
500 |
<xsl:if test="$OPACURLOpenInNewWindow='1'"> |
501 |
<xsl:attribute name="target">_blank</xsl:attribute> |
502 |
</xsl:if> |
503 |
<xsl:choose> |
504 |
<xsl:when test="($Show856uAsImage='Details' or $Show856uAsImage='Both') and (substring($SubqText,1,6)='image/' or $SubqText='img' or $SubqText='bmp' or $SubqText='cod' or $SubqText='gif' or $SubqText='ief' or $SubqText='jpe' or $SubqText='jpeg' or $SubqText='jpg' or $SubqText='jfif' or $SubqText='png' or $SubqText='svg' or $SubqText='tif' or $SubqText='tiff' or $SubqText='ras' or $SubqText='cmx' or $SubqText='ico' or $SubqText='pnm' or $SubqText='pbm' or $SubqText='pgm' or $SubqText='ppm' or $SubqText='rgb' or $SubqText='xbm' or $SubqText='xpm' or $SubqText='xwd')"> |
505 |
<xsl:element name="img"><xsl:attribute name="src"><xsl:value-of select="marc:subfield[@code='u']"/></xsl:attribute><xsl:attribute name="alt"><xsl:value-of select="marc:subfield[@code='y']"/></xsl:attribute><xsl:attribute name="style">height:100px</xsl:attribute></xsl:element><xsl:text></xsl:text> |
506 |
</xsl:when> |
484 |
<xsl:when test="marc:subfield[@code='y' or @code='3' or @code='z']"> |
507 |
<xsl:when test="marc:subfield[@code='y' or @code='3' or @code='z']"> |
485 |
<xsl:call-template name="subfieldSelect"> |
508 |
<xsl:call-template name="subfieldSelect"> |
486 |
<xsl:with-param name="codes">y3z</xsl:with-param> |
509 |
<xsl:with-param name="codes">y3z</xsl:with-param> |
487 |
</xsl:call-template> |
510 |
</xsl:call-template> |
488 |
</xsl:when> |
511 |
</xsl:when> |
489 |
<xsl:when test="not(marc:subfield[@code='y']) and not(marc:subfield[@code='3']) and not(marc:subfield[@code='z'])"> |
512 |
<xsl:when test="$URLLinkText!=''"> |
490 |
Klikk her for tilgang |
513 |
<xsl:value-of select="$URLLinkText"/> |
491 |
</xsl:when> |
514 |
</xsl:when> |
492 |
</xsl:choose> |
515 |
<xsl:otherwise> |
493 |
</a> |
516 |
<xsl:text>Click here to access online</xsl:text> |
|
|
517 |
</xsl:otherwise> |
518 |
</xsl:choose> |
519 |
</a> |
494 |
<xsl:choose> |
520 |
<xsl:choose> |
495 |
<xsl:when test="position()=last()"></xsl:when> |
521 |
<xsl:when test="position()=last()"><xsl:text> </xsl:text></xsl:when> |
496 |
<xsl:otherwise> | </xsl:otherwise> |
522 |
<xsl:otherwise> | </xsl:otherwise> |
497 |
</xsl:choose> |
523 |
</xsl:choose> |
498 |
</xsl:for-each> |
524 |
</xsl:for-each> |