View | Details | Raw Unified | Return to bug 14716
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2ATOM.xsl (-1 / +1 lines)
Lines 23-29 Link Here
23
			<xsl:for-each select="marc:controlfield[@tag=001]">
23
			<xsl:for-each select="marc:controlfield[@tag=001]">
24
				<id>
24
				<id>
25
					<xsl:text>urn:tcn:</xsl:text>
25
					<xsl:text>urn:tcn:</xsl:text>
26
					<xsl:value-of select="."/>
26
					<xsl:value-of select="str:encode-uri(., true())"/>
27
				</id>
27
				</id>
28
			</xsl:for-each>
28
			</xsl:for-each>
29
29
(-)a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetDetail.xsl (-7 / +7 lines)
Lines 261-267 Link Here
261
            <a>
261
            <a>
262
            <xsl:choose>
262
            <xsl:choose>
263
            <xsl:when test="$UseControlNumber = '1' and marc:controlfield[@tag=001]">
263
            <xsl:when test="$UseControlNumber = '1' and marc:controlfield[@tag=001]">
264
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=rcn:<xsl:value-of select="marc:controlfield[@tag=001]"/>+and+(bib-level:a+or+bib-level:b)</xsl:attribute>
264
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=rcn:<xsl:value-of select="str:encode-uri(marc:controlfield[@tag=001], true())"/>+and+(bib-level:a+or+bib-level:b)</xsl:attribute>
265
            </xsl:when>
265
            </xsl:when>
266
            <xsl:otherwise>
266
            <xsl:otherwise>
267
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=Host-item:<xsl:value-of select="str:encode-uri(translate(marc:datafield[@tag=245]/marc:subfield[@code='a'], '/', ''), true())"/></xsl:attribute>
267
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=Host-item:<xsl:value-of select="str:encode-uri(translate(marc:datafield[@tag=245]/marc:subfield[@code='a'], '/', ''), true())"/></xsl:attribute>
Lines 278-284 Link Here
278
            <a>
278
            <a>
279
            <xsl:choose>
279
            <xsl:choose>
280
            <xsl:when test="$UseControlNumber = '1' and marc:controlfield[@tag=001]">
280
            <xsl:when test="$UseControlNumber = '1' and marc:controlfield[@tag=001]">
281
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=rcn:<xsl:value-of select="marc:controlfield[@tag=001]"/>+not+(bib-level:a+or+bib-level:b)</xsl:attribute>
281
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=rcn:<xsl:value-of select="str:encode-uri(marc:controlfield[@tag=001], true())"/>+not+(bib-level:a+or+bib-level:b)</xsl:attribute>
282
            </xsl:when>
282
            </xsl:when>
283
            <xsl:otherwise>
283
            <xsl:otherwise>
284
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=ti,phr:<xsl:value-of select="str:encode-uri(translate(marc:datafield[@tag=245]/marc:subfield[@code='a'], '/', ''), true())"/></xsl:attribute>
284
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=ti,phr:<xsl:value-of select="str:encode-uri(translate(marc:datafield[@tag=245]/marc:subfield[@code='a'], '/', ''), true())"/></xsl:attribute>
Lines 653-659 Link Here
653
            <xsl:choose>
653
            <xsl:choose>
654
            <!-- #1807 Strip unwanted parenthesis from subjects for searching -->
654
            <!-- #1807 Strip unwanted parenthesis from subjects for searching -->
655
            <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
655
            <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
656
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
656
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
657
            </xsl:when>
657
            </xsl:when>
658
            <xsl:when test="$TraceSubjectSubdivisions='1'">
658
            <xsl:when test="$TraceSubjectSubdivisions='1'">
659
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=<xsl:call-template name="subfieldSelectSubject">
659
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=<xsl:call-template name="subfieldSelectSubject">
Lines 686-692 Link Here
686
            <xsl:if test="marc:subfield[@code=9]">
686
            <xsl:if test="marc:subfield[@code=9]">
687
                <xsl:text> </xsl:text>
687
                <xsl:text> </xsl:text>
688
                <a class='authlink'>
688
                <a class='authlink'>
689
                    <xsl:attribute name="href">/cgi-bin/koha/authorities/detail.pl?authid=<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
689
                    <xsl:attribute name="href">/cgi-bin/koha/authorities/detail.pl?authid=<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
690
                    <xsl:element name="img">
690
                    <xsl:element name="img">
691
                        <xsl:attribute name="src">/intranet-tmpl/prog/img/filefind.png</xsl:attribute>
691
                        <xsl:attribute name="src">/intranet-tmpl/prog/img/filefind.png</xsl:attribute>
692
                        <xsl:attribute name="alt"></xsl:attribute>
692
                        <xsl:attribute name="alt"></xsl:attribute>
Lines 712-718 Link Here
712
                    <a>
712
                    <a>
713
                        <xsl:choose>
713
                        <xsl:choose>
714
                            <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
714
                            <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
715
                                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
715
                                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
716
                            </xsl:when>
716
                            </xsl:when>
717
                            <xsl:when test="$TraceSubjectSubdivisions='1'">
717
                            <xsl:when test="$TraceSubjectSubdivisions='1'">
718
                                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=<xsl:call-template name="subfieldSelect">
718
                                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=<xsl:call-template name="subfieldSelect">
Lines 967-973 Link Here
967
                            </a>
967
                            </a>
968
                        </xsl:when>
968
                        </xsl:when>
969
                        <xsl:when test="marc:subfield[@code='0']">
969
                        <xsl:when test="marc:subfield[@code='0']">
970
                            <a><xsl:attribute name="href">/cgi-bin/koha/catalogue/detail.pl?biblionumber=<xsl:value-of select="marc:subfield[@code='0']"/></xsl:attribute>
970
                            <a><xsl:attribute name="href">/cgi-bin/koha/catalogue/detail.pl?biblionumber=<xsl:value-of select="str:encode-uri(marc:subfield[@code='0'], true())"/></xsl:attribute>
971
                            <xsl:value-of select="$f773"/>
971
                            <xsl:value-of select="$f773"/>
972
                            </a>
972
                            </a>
973
                        </xsl:when>
973
                        </xsl:when>
Lines 1168-1174 Link Here
1168
1168
1169
        <xsl:if test="$OPACBaseURL!=''">
1169
        <xsl:if test="$OPACBaseURL!=''">
1170
        <span class="results_summary"><span class="label">OPAC view: </span>
1170
        <span class="results_summary"><span class="label">OPAC view: </span>
1171
            <a><xsl:attribute name="href"><xsl:value-of select="$OPACBaseURL"/>/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of select="marc:datafield[@tag=999]/marc:subfield[@code='c']"/></xsl:attribute><xsl:attribute name="target">_blank</xsl:attribute>Open in new window</a>.
1171
            <a><xsl:attribute name="href"><xsl:value-of select="$OPACBaseURL"/>/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of select="str:encode-uri(marc:datafield[@tag=999]/marc:subfield[@code='c'], true())"/></xsl:attribute><xsl:attribute name="target">_blank</xsl:attribute>Open in new window</a>.
1172
        </span>
1172
        </span>
1173
        </xsl:if>
1173
        </xsl:if>
1174
1174
(-)a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slim2intranetResults.xsl (-2 / +2 lines)
Lines 306-312 Link Here
306
                    <xsl:value-of select="$IntranetBiblioDefaultView"/>
306
                    <xsl:value-of select="$IntranetBiblioDefaultView"/>
307
                </xsl:with-param>
307
                </xsl:with-param>
308
            </xsl:call-template>
308
            </xsl:call-template>
309
            <xsl:value-of select="$biblionumber"/>
309
            <xsl:value-of select="str:encode-uri($biblionumber, true())"/>
310
        </xsl:attribute>
310
        </xsl:attribute>
311
        <xsl:attribute name="class">title</xsl:attribute>
311
        <xsl:attribute name="class">title</xsl:attribute>
312
312
Lines 354-360 Link Here
354
            <a>
354
            <a>
355
                <xsl:choose>
355
                <xsl:choose>
356
                    <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
356
                    <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
357
                        <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
357
                        <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
358
                    </xsl:when>
358
                    </xsl:when>
359
                    <xsl:otherwise>
359
                    <xsl:otherwise>
360
                        <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:"<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/>"</xsl:attribute>
360
                        <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:"<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/>"</xsl:attribute>
(-)a/koha-tmpl/intranet-tmpl/prog/en/xslt/MARC21slimUtils.xsl (-5 / +6 lines)
Lines 44-50 Link Here
44
		</xsl:variable>
44
		</xsl:variable>
45
        <xsl:choose>
45
        <xsl:choose>
46
            <xsl:when test="$urlencode=1">
46
            <xsl:when test="$urlencode=1">
47
                <xsl:value-of select="str:encode-uri(substring($str,1,string-length($str)-string-length($delimeter))    )"/>
47
                <xsl:value-of select="str:encode-uri(substring($str,1,string-length($str)-string-length($delimeter)), true())"/>
48
            </xsl:when>
48
            </xsl:when>
49
            <xsl:otherwise>
49
            <xsl:otherwise>
50
                <xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/>
50
                <xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/>
Lines 125-140 Link Here
125
	     Assumes LOC convention: (OrgCode)recordNumber.
125
	     Assumes LOC convention: (OrgCode)recordNumber.
126
	     If OrgCode is not present, return full string.
126
	     If OrgCode is not present, return full string.
127
	     Additionally, handle various brackets/parentheses. Chop leading and trailing spaces.
127
	     Additionally, handle various brackets/parentheses. Chop leading and trailing spaces.
128
         Returns the value URI-encoded.
128
	-->
129
	-->
129
	<xsl:template name="extractControlNumber">
130
	<xsl:template name="extractControlNumber">
130
	    <xsl:param name="subfieldW"/>
131
	    <xsl:param name="subfieldW"/>
131
	    <xsl:variable name="tranW" select="translate($subfieldW,']})&gt;','))))')"/>
132
	    <xsl:variable name="tranW" select="translate($subfieldW,']})&gt;','))))')"/>
132
	    <xsl:choose>
133
	    <xsl:choose>
133
	      <xsl:when test="contains($tranW,')')">
134
	      <xsl:when test="contains($tranW,')')">
134
	        <xsl:value-of select="normalize-space(translate(substring-after($tranW,')'),'[]{}()&lt;&gt;',''))"/>
135
	        <xsl:value-of select="str:encode-uri(normalize-space(translate(substring-after($tranW,')'),'[]{}()&lt;&gt;','')), true())"/>
135
	      </xsl:when>
136
	      </xsl:when>
136
	      <xsl:otherwise>
137
	      <xsl:otherwise>
137
	        <xsl:value-of select="normalize-space($subfieldW)"/>
138
	        <xsl:value-of select="str:encode-uri(normalize-space($subfieldW), true())"/>
138
	      </xsl:otherwise>
139
	      </xsl:otherwise>
139
	    </xsl:choose>
140
	    </xsl:choose>
140
	</xsl:template>
141
	</xsl:template>
Lines 197-209 Link Here
197
                    <xsl:choose>
198
                    <xsl:choose>
198
                        <xsl:when test="boolean($bibno)">
199
                        <xsl:when test="boolean($bibno)">
199
                            <a>
200
                            <a>
200
                                <xsl:attribute name="href">/cgi-bin/koha/catalogue/detail.pl?biblionumber=<xsl:value-of  select="$bibno"/></xsl:attribute>
201
                                <xsl:attribute name="href">/cgi-bin/koha/catalogue/detail.pl?biblionumber=<xsl:value-of  select="str:encode-uri($bibno, true())"/></xsl:attribute>
201
                                <xsl:value-of select="$str"/>
202
                                <xsl:value-of select="$str"/>
202
                            </a>
203
                            </a>
203
                        </xsl:when>
204
                        </xsl:when>
204
                       <xsl:when test="boolean($index) and boolean(marc:subfield[@code=9]) and $UseAuthoritiesForTracings='1'">
205
                       <xsl:when test="boolean($index) and boolean(marc:subfield[@code=9]) and $UseAuthoritiesForTracings='1'">
205
                            <a>
206
                            <a>
206
                                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of  select="marc:subfield[@code=9]"/></xsl:attribute>
207
                                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of  select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
207
                                  <xsl:value-of select="$str"/>
208
                                  <xsl:value-of select="$str"/>
208
                            </a>
209
                            </a>
209
                        </xsl:when>
210
                        </xsl:when>
(-)a/koha-tmpl/intranet-tmpl/prog/en/xslt/NORMARCslim2intranetDetail.xsl (-6 / +7 lines)
Lines 106-112 Link Here
106
        <a>
106
        <a>
107
        <xsl:choose>
107
        <xsl:choose>
108
            <xsl:when test="marc:subfield[@code=9]">
108
            <xsl:when test="marc:subfield[@code=9]">
109
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
109
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
110
            </xsl:when>
110
            </xsl:when>
111
            <xsl:otherwise>
111
            <xsl:otherwise>
112
            <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
112
            <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
Lines 121-127 Link Here
121
        <a>
121
        <a>
122
        <xsl:choose>
122
        <xsl:choose>
123
            <xsl:when test="marc:subfield[@code=9]">
123
            <xsl:when test="marc:subfield[@code=9]">
124
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
124
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
125
            </xsl:when>
125
            </xsl:when>
126
            <xsl:otherwise>
126
            <xsl:otherwise>
127
            <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
127
            <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
Lines 135-141 Link Here
135
        <a>
135
        <a>
136
        <xsl:choose>
136
        <xsl:choose>
137
            <xsl:when test="marc:subfield[@code=9]">
137
            <xsl:when test="marc:subfield[@code=9]">
138
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
138
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
139
            </xsl:when>
139
            </xsl:when>
140
            <xsl:otherwise>
140
            <xsl:otherwise>
141
            <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
141
            <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
Lines 248-254 Link Here
248
                    <xsl:if test="marc:subfield[@code='g']"><xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='g']"/></xsl:if>
248
                    <xsl:if test="marc:subfield[@code='g']"><xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='g']"/></xsl:if>
249
                </xsl:when>
249
                </xsl:when>
250
                <xsl:when test="marc:subfield[@code='0']">
250
                <xsl:when test="marc:subfield[@code='0']">
251
                    <a><xsl:attribute name="href">/cgi-bin/koha/catalogue/detail.pl?biblionumber=<xsl:value-of select="marc:subfield[@code='0']"/></xsl:attribute>
251
                    <a><xsl:attribute name="href">/cgi-bin/koha/catalogue/detail.pl?biblionumber=<xsl:value-of select="str:encode-uri(marc:subfield[@code='0'], true())"/></xsl:attribute>
252
                        <xsl:value-of select="$f773"/>
252
                        <xsl:value-of select="$f773"/>
253
                    </a>
253
                    </a>
254
                </xsl:when>
254
                </xsl:when>
Lines 408-414 Link Here
408
            <xsl:choose>
408
            <xsl:choose>
409
            <!-- Will implement this later
409
            <!-- Will implement this later
410
                <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
410
                <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
411
                    <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
411
                    <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
412
                </xsl:when>
412
                </xsl:when>
413
            -->
413
            -->
414
            <xsl:when test="$TraceSubjectSubdivisions='1'">
414
            <xsl:when test="$TraceSubjectSubdivisions='1'">
Lines 417-422 Link Here
417
                        <xsl:with-param name="delimeter"> AND </xsl:with-param>
417
                        <xsl:with-param name="delimeter"> AND </xsl:with-param>
418
                        <xsl:with-param name="prefix">(su<xsl:value-of select="$SubjectModifier"/>:<xsl:value-of select="$TracingQuotesLeft"/></xsl:with-param>
418
                        <xsl:with-param name="prefix">(su<xsl:value-of select="$SubjectModifier"/>:<xsl:value-of select="$TracingQuotesLeft"/></xsl:with-param>
419
                        <xsl:with-param name="suffix"><xsl:value-of select="$TracingQuotesRight"/>)</xsl:with-param>
419
                        <xsl:with-param name="suffix"><xsl:value-of select="$TracingQuotesRight"/>)</xsl:with-param>
420
                        <xsl:with-param name="urlencode">1</xsl:with-param>
420
                    </xsl:call-template>
421
                    </xsl:call-template>
421
                </xsl:attribute>
422
                </xsl:attribute>
422
            </xsl:when>
423
            </xsl:when>
Lines 602-608 Link Here
602
        <!-- This will only work if the OPACBaseURL syspref is set. -->
603
        <!-- This will only work if the OPACBaseURL syspref is set. -->
603
        <xsl:if test="string-length($OPACBaseURL) > 0">
604
        <xsl:if test="string-length($OPACBaseURL) > 0">
604
        <p>OPAC View: <a>
605
        <p>OPAC View: <a>
605
                      <xsl:attribute name="href"><xsl:value-of select="$OPACBaseURL"/>/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of select="$biblionumber"/></xsl:attribute>
606
                      <xsl:attribute name="href"><xsl:value-of select="$OPACBaseURL"/>/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of select="str:encode-uri($biblionumber, true())"/></xsl:attribute>
606
                      <xsl:attribute name="target">_blank</xsl:attribute>
607
                      <xsl:attribute name="target">_blank</xsl:attribute>
607
                      Open in new window
608
                      Open in new window
608
                      </a></p>
609
                      </a></p>
(-)a/koha-tmpl/intranet-tmpl/prog/en/xslt/NORMARCslim2intranetResults.xsl (-5 / +5 lines)
Lines 260-266 Link Here
260
                    <xsl:value-of select="$IntranetBiblioDefaultView"/>
260
                    <xsl:value-of select="$IntranetBiblioDefaultView"/>
261
                </xsl:with-param>
261
                </xsl:with-param>
262
            </xsl:call-template>
262
            </xsl:call-template>
263
            <xsl:value-of select="$biblionumber"/>
263
            <xsl:value-of select="str:encode-uri($biblionumber, true())"/>
264
        </xsl:attribute>
264
        </xsl:attribute>
265
        <xsl:attribute name="class">title</xsl:attribute>
265
        <xsl:attribute name="class">title</xsl:attribute>
266
266
Lines 306-312 Link Here
306
    <a>
306
    <a>
307
    <xsl:choose>
307
    <xsl:choose>
308
        <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
308
        <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
309
            <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
309
            <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
310
        </xsl:when>
310
        </xsl:when>
311
        <xsl:otherwise>
311
        <xsl:otherwise>
312
        <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:"<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/>"</xsl:attribute>
312
        <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:"<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/>"</xsl:attribute>
Lines 321-327 Link Here
321
    <a>
321
    <a>
322
    <xsl:choose>
322
    <xsl:choose>
323
        <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
323
        <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
324
            <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
324
            <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
325
        </xsl:when>
325
        </xsl:when>
326
        <xsl:otherwise>
326
        <xsl:otherwise>
327
        <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:"<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/>"</xsl:attribute>
327
        <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:"<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/>"</xsl:attribute>
Lines 343-349 Link Here
343
    <a>
343
    <a>
344
    <xsl:choose>
344
    <xsl:choose>
345
        <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
345
        <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
346
            <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
346
            <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
347
        </xsl:when>
347
        </xsl:when>
348
        <xsl:otherwise>
348
        <xsl:otherwise>
349
        <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:"<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/>"</xsl:attribute>
349
        <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:"<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/>"</xsl:attribute>
Lines 448-454 Link Here
448
                    <xsl:if test="marc:subfield[@code='g']"><xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='g']"/></xsl:if>
448
                    <xsl:if test="marc:subfield[@code='g']"><xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='g']"/></xsl:if>
449
                </xsl:when>
449
                </xsl:when>
450
                <xsl:when test="marc:subfield[@code='0']">
450
                <xsl:when test="marc:subfield[@code='0']">
451
                    <a><xsl:attribute name="href">/cgi-bin/koha/catalogue/detail.pl?biblionumber=<xsl:value-of select="marc:subfield[@code='0']"/></xsl:attribute>
451
                    <a><xsl:attribute name="href">/cgi-bin/koha/catalogue/detail.pl?biblionumber=<xsl:value-of select="str:encode-uri(marc:subfield[@code='0'], true())"/></xsl:attribute>
452
                        <xsl:value-of select="$f773"/>
452
                        <xsl:value-of select="$f773"/>
453
                    </a>
453
                    </a>
454
                </xsl:when>
454
                </xsl:when>
(-)a/koha-tmpl/intranet-tmpl/prog/en/xslt/NORMARCslimUtils.xsl (-5 / +14 lines)
Lines 32-37 Link Here
32
		<xsl:param name="subdivDelimiter"/>
32
		<xsl:param name="subdivDelimiter"/>
33
        <xsl:param name="prefix"/>
33
        <xsl:param name="prefix"/>
34
        <xsl:param name="suffix"/>
34
        <xsl:param name="suffix"/>
35
        <xsl:param name="urlencode"/>
35
		<xsl:variable name="str">
36
		<xsl:variable name="str">
36
			<xsl:for-each select="marc:subfield">
37
			<xsl:for-each select="marc:subfield">
37
				<xsl:if test="contains($codes, @code)">
38
				<xsl:if test="contains($codes, @code)">
Lines 42-48 Link Here
42
				</xsl:if>
43
				</xsl:if>
43
			</xsl:for-each>
44
			</xsl:for-each>
44
		</xsl:variable>
45
		</xsl:variable>
45
		<xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/>
46
        <xsl:choose>
47
            <xsl:when test="$urlencode=1">
48
                <xsl:value-of select="str:encode-uri(substring($str,1,string-length($str)-string-length($delimeter)), true())"/>
49
            </xsl:when>
50
            <xsl:otherwise>
51
                <xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/>
52
            </xsl:otherwise>
53
        </xsl:choose>
46
	</xsl:template>
54
	</xsl:template>
47
55
48
	<xsl:template name="buildSpaces">
56
	<xsl:template name="buildSpaces">
Lines 99-114 Link Here
99
	     Assumes LOC convention: (OrgCode)recordNumber.
107
	     Assumes LOC convention: (OrgCode)recordNumber.
100
	     If OrgCode is not present, return full string.
108
	     If OrgCode is not present, return full string.
101
	     Additionally, handle various brackets/parentheses. Chop leading and trailing spaces.
109
	     Additionally, handle various brackets/parentheses. Chop leading and trailing spaces.
110
         Returns the value URI-encoded.
102
	-->
111
	-->
103
	<xsl:template name="extractControlNumber">
112
	<xsl:template name="extractControlNumber">
104
	    <xsl:param name="subfieldW"/>
113
	    <xsl:param name="subfieldW"/>
105
	    <xsl:variable name="tranW" select="translate($subfieldW,']})&gt;','))))')"/>
114
	    <xsl:variable name="tranW" select="translate($subfieldW,']})&gt;','))))')"/>
106
	    <xsl:choose>
115
	    <xsl:choose>
107
	      <xsl:when test="contains($tranW,')')">
116
	      <xsl:when test="contains($tranW,')')">
108
	        <xsl:value-of select="normalize-space(translate(substring-after($tranW,')'),'[]{}()&lt;&gt;',''))"/>
117
	        <xsl:value-of select="str:encode-uri(normalize-space(translate(substring-after($tranW,')'),'[]{}()&lt;&gt;','')), true())"/>
109
	      </xsl:when>
118
	      </xsl:when>
110
	      <xsl:otherwise>
119
	      <xsl:otherwise>
111
	        <xsl:value-of select="normalize-space($subfieldW)"/>
120
	        <xsl:value-of select="str:encode-uri(normalize-space($subfieldW), true())"/>
112
	      </xsl:otherwise>
121
	      </xsl:otherwise>
113
	    </xsl:choose>
122
	    </xsl:choose>
114
	</xsl:template>
123
	</xsl:template>
Lines 218-230 Link Here
218
                    <xsl:choose>
227
                    <xsl:choose>
219
                        <xsl:when test="boolean($bibno)">
228
                        <xsl:when test="boolean($bibno)">
220
                            <a>
229
                            <a>
221
                                <xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of  select="$bibno"/></xsl:attribute>
230
                                <xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of  select="str:encode-uri($bibno, true())"/></xsl:attribute>
222
                                <xsl:value-of select="$str"/>
231
                                <xsl:value-of select="$str"/>
223
                            </a>
232
                            </a>
224
                        </xsl:when>
233
                        </xsl:when>
225
                       <xsl:when test="boolean($index) and boolean(marc:subfield[@code=9])">
234
                       <xsl:when test="boolean($index) and boolean(marc:subfield[@code=9])">
226
                            <a>
235
                            <a>
227
                                <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of  select="marc:subfield[@code=9]"/></xsl:attribute>
236
                                <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of  select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
228
                                  <xsl:value-of select="$str"/>
237
                                  <xsl:value-of select="$str"/>
229
                            </a>
238
                            </a>
230
                        </xsl:when>
239
                        </xsl:when>
(-)a/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslim2intranetResults.xsl (-1 / +1 lines)
Lines 34-40 Link Here
34
              <xsl:value-of select="$IntranetBiblioDefaultView"/>
34
              <xsl:value-of select="$IntranetBiblioDefaultView"/>
35
            </xsl:with-param>
35
            </xsl:with-param>
36
          </xsl:call-template>
36
          </xsl:call-template>
37
          <xsl:value-of select="$biblionumber"/>
37
          <xsl:value-of select="str:encode-uri($biblionumber, true())"/>
38
        </xsl:attribute>
38
        </xsl:attribute>
39
        <xsl:attribute name="class">title</xsl:attribute>
39
        <xsl:attribute name="class">title</xsl:attribute>
40
40
(-)a/koha-tmpl/intranet-tmpl/prog/en/xslt/UNIMARCslimUtils.xsl (-3 / +11 lines)
Lines 115-120 Link Here
115
		<xsl:param name="delimeter"><xsl:text> </xsl:text></xsl:param>
115
		<xsl:param name="delimeter"><xsl:text> </xsl:text></xsl:param>
116
		<xsl:param name="subdivCodes"/>
116
		<xsl:param name="subdivCodes"/>
117
		<xsl:param name="subdivDelimiter"/>
117
		<xsl:param name="subdivDelimiter"/>
118
    <xsl:param name="urlencode"/>
118
		<xsl:variable name="str">
119
		<xsl:variable name="str">
119
			<xsl:for-each select="marc:subfield">
120
			<xsl:for-each select="marc:subfield">
120
				<xsl:if test="contains($codes, @code)">
121
				<xsl:if test="contains($codes, @code)">
Lines 125-131 Link Here
125
				</xsl:if>
126
				</xsl:if>
126
			</xsl:for-each>
127
			</xsl:for-each>
127
		</xsl:variable>
128
		</xsl:variable>
128
		<xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/>
129
    <xsl:choose>
130
      <xsl:when test="$urlencode=1">
131
        <xsl:value-of select="str:encode-uri(substring($str,1,string-length($str)-string-length($delimeter)), true())"/>
132
      </xsl:when>
133
      <xsl:otherwise>
134
        <xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/>
135
      </xsl:otherwise>
136
    </xsl:choose>
129
	</xsl:template>
137
	</xsl:template>
130
138
131
	<xsl:template name="buildSpaces">
139
	<xsl:template name="buildSpaces">
Lines 250-256 Link Here
250
          <a>
258
          <a>
251
            <xsl:choose>
259
            <xsl:choose>
252
              <xsl:when test="marc:subfield[@code=9]">
260
              <xsl:when test="marc:subfield[@code=9]">
253
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
261
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
254
              </xsl:when>
262
              </xsl:when>
255
              <xsl:otherwise>
263
              <xsl:otherwise>
256
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=su:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
264
                <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=su:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
Lines 287-293 Link Here
287
            <a>
295
            <a>
288
              <xsl:choose>
296
              <xsl:choose>
289
                <xsl:when test="marc:subfield[@code=9]">
297
                <xsl:when test="marc:subfield[@code=9]">
290
                  <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
298
                  <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
291
                </xsl:when>
299
                </xsl:when>
292
                <xsl:otherwise>
300
                <xsl:otherwise>
293
                  <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/><xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='b']"/></xsl:attribute>
301
                  <xsl:attribute name="href">/cgi-bin/koha/catalogue/search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/><xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='b']"/></xsl:attribute>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACDetail.xsl (-12 / +12 lines)
Lines 725-731 Link Here
725
            <a>
725
            <a>
726
            <xsl:choose>
726
            <xsl:choose>
727
            <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
727
            <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
728
                <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
728
                <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
729
            </xsl:when>
729
            </xsl:when>
730
            <!-- #1807 Strip unwanted parenthesis from subjects for searching -->
730
            <!-- #1807 Strip unwanted parenthesis from subjects for searching -->
731
            <xsl:when test="$TraceSubjectSubdivisions='1'">
731
            <xsl:when test="$TraceSubjectSubdivisions='1'">
Lines 756-762 Link Here
756
            </span>
756
            </span>
757
            <xsl:if test="marc:subfield[@code=9]">
757
            <xsl:if test="marc:subfield[@code=9]">
758
                <a class='authlink'>
758
                <a class='authlink'>
759
                    <xsl:attribute name="href">/cgi-bin/koha/opac-authoritiesdetail.pl?authid=<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
759
                    <xsl:attribute name="href">/cgi-bin/koha/opac-authoritiesdetail.pl?authid=<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
760
                    <xsl:element name="img">
760
                    <xsl:element name="img">
761
                        <xsl:attribute name="src">/opac-tmpl/<xsl:value-of select="$theme"/>/images/filefind.png</xsl:attribute>
761
                        <xsl:attribute name="src">/opac-tmpl/<xsl:value-of select="$theme"/>/images/filefind.png</xsl:attribute>
762
                        <xsl:attribute name="style">vertical-align:middle</xsl:attribute>
762
                        <xsl:attribute name="style">vertical-align:middle</xsl:attribute>
Lines 781-787 Link Here
781
                        <a>
781
                        <a>
782
                            <xsl:choose>
782
                            <xsl:choose>
783
                                <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
783
                                <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
784
                                    <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
784
                                    <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
785
                                </xsl:when>
785
                                </xsl:when>
786
                                <xsl:when test="$TraceSubjectSubdivisions='1'">
786
                                <xsl:when test="$TraceSubjectSubdivisions='1'">
787
                                    <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=<xsl:call-template name="subfieldSelectSubject">
787
                                    <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=<xsl:call-template name="subfieldSelectSubject">
Lines 839-845 Link Here
839
                        <xsl:text>/cgi-bin/koha/opac-search.pl?q=control-number:</xsl:text>
839
                        <xsl:text>/cgi-bin/koha/opac-search.pl?q=control-number:</xsl:text>
840
                        <xsl:call-template name="extractControlNumber">
840
                        <xsl:call-template name="extractControlNumber">
841
                            <xsl:with-param name="subfieldW">
841
                            <xsl:with-param name="subfieldW">
842
                                <xsl:value-of select="str:encode-uri(marc:subfield[@code='w'], true())"/>
842
                                <xsl:value-of select="marc:subfield[@code='w']"/>
843
                            </xsl:with-param>
843
                            </xsl:with-param>
844
                        </xsl:call-template>
844
                        </xsl:call-template>
845
                    </xsl:attribute>
845
                    </xsl:attribute>
Lines 1070-1081 Link Here
1070
                            </a>
1070
                            </a>
1071
                        </xsl:when>
1071
                        </xsl:when>
1072
                        <xsl:when test="marc:subfield[@code='0']">
1072
                        <xsl:when test="marc:subfield[@code='0']">
1073
                            <a><xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of select="marc:subfield[@code='0']"/></xsl:attribute>
1073
                            <a><xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of select="str:encode-uri(marc:subfield[@code='0'], true())"/></xsl:attribute>
1074
                            <xsl:value-of select="$f773"/>
1074
                            <xsl:value-of select="$f773"/>
1075
                            </a>
1075
                            </a>
1076
                        </xsl:when>
1076
                        </xsl:when>
1077
                        <xsl:otherwise>
1077
                        <xsl:otherwise>
1078
                            <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=ti,phr:<xsl:value-of select="translate($f773, '()', '')"/></xsl:attribute>
1078
                            <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=ti,phr:<xsl:value-of select="str:encode-uri(translate($f773, '()', ''), true())"/></xsl:attribute>
1079
                            <xsl:value-of select="$f773"/>
1079
                            <xsl:value-of select="$f773"/>
1080
                            </a>
1080
                            </a>
1081
                        </xsl:otherwise>
1081
                        </xsl:otherwise>
Lines 1166-1172 Link Here
1166
                <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>
1166
                <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>
1167
            </xsl:when>
1167
            </xsl:when>
1168
            <xsl:otherwise>
1168
            <xsl:otherwise>
1169
                <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=ti,phr:<xsl:value-of select="translate($f775, '()', '')"/></xsl:attribute>
1169
                <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=ti,phr:<xsl:value-of select="str:encode-uri(translate($f775, '()', ''), true())"/></xsl:attribute>
1170
            </xsl:otherwise>
1170
            </xsl:otherwise>
1171
            </xsl:choose>
1171
            </xsl:choose>
1172
            <xsl:call-template name="subfieldSelect">
1172
            <xsl:call-template name="subfieldSelect">
Lines 1225-1231 Link Here
1225
                    </a>
1225
                    </a>
1226
                </xsl:when>
1226
                </xsl:when>
1227
                <xsl:otherwise>
1227
                <xsl:otherwise>
1228
                    <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=ti,phr:<xsl:value-of select="translate($f780, '()', '')"/></xsl:attribute>
1228
                    <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=ti,phr:<xsl:value-of select="str:encode-uri(translate($f780, '()', ''), true())"/></xsl:attribute>
1229
                        <xsl:value-of select="translate($f780, '()', '')"/>
1229
                        <xsl:value-of select="translate($f780, '()', '')"/>
1230
                    </a>
1230
                    </a>
1231
                </xsl:otherwise>
1231
                </xsl:otherwise>
Lines 1288-1294 Link Here
1288
                    </a>
1288
                    </a>
1289
                </xsl:when>
1289
                </xsl:when>
1290
                <xsl:otherwise>
1290
                <xsl:otherwise>
1291
                    <a><xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=ti,phr:<xsl:value-of select="translate($f785, '()', '')"/></xsl:attribute>
1291
                    <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>
1292
                        <xsl:value-of select="translate($f785, '()', '')"/>
1292
                        <xsl:value-of select="translate($f785, '()', '')"/>
1293
                    </a>
1293
                    </a>
1294
                </xsl:otherwise>
1294
                </xsl:otherwise>
Lines 1335-1344 Link Here
1335
            <a>
1335
            <a>
1336
                <xsl:choose>
1336
                <xsl:choose>
1337
                    <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
1337
                    <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
1338
                        <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:"<xsl:value-of select="marc:subfield[@code=9]"/>"</xsl:attribute>
1338
                        <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:"<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/>"</xsl:attribute>
1339
                    </xsl:when>
1339
                    </xsl:when>
1340
                    <xsl:otherwise>
1340
                    <xsl:otherwise>
1341
                        <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=au:"<xsl:value-of select="marc:subfield[@code='a']"/>"</xsl:attribute>
1341
                        <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=au:"<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/>"</xsl:attribute>
1342
                    </xsl:otherwise>
1342
                    </xsl:otherwise>
1343
                </xsl:choose>
1343
                </xsl:choose>
1344
                <span resource="#record"><span>
1344
                <span resource="#record"><span>
Lines 1568-1574 Link Here
1568
            </a>
1568
            </a>
1569
            <xsl:if test="marc:subfield[@code=9]">
1569
            <xsl:if test="marc:subfield[@code=9]">
1570
                <a class='authlink'>
1570
                <a class='authlink'>
1571
                    <xsl:attribute name="href">/cgi-bin/koha/opac-authoritiesdetail.pl?authid=<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
1571
                    <xsl:attribute name="href">/cgi-bin/koha/opac-authoritiesdetail.pl?authid=<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
1572
                    <xsl:element name="img">
1572
                    <xsl:element name="img">
1573
                        <xsl:attribute name="src">/opac-tmpl/<xsl:value-of select="$theme"/>/images/filefind.png</xsl:attribute>
1573
                        <xsl:attribute name="src">/opac-tmpl/<xsl:value-of select="$theme"/>/images/filefind.png</xsl:attribute>
1574
                        <xsl:attribute name="style">vertical-align:middle</xsl:attribute>
1574
                        <xsl:attribute name="style">vertical-align:middle</xsl:attribute>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slim2OPACResults.xsl (-1 / +1 lines)
Lines 413-419 Link Here
413
                    <xsl:value-of select="$BiblioDefaultView"/>
413
                    <xsl:value-of select="$BiblioDefaultView"/>
414
                </xsl:with-param>
414
                </xsl:with-param>
415
            </xsl:call-template>
415
            </xsl:call-template>
416
            <xsl:value-of select="$biblionumber"/>
416
            <xsl:value-of select="str:encode-uri($biblionumber, true())"/>
417
        </xsl:attribute>
417
        </xsl:attribute>
418
        <xsl:attribute name="class">title</xsl:attribute>
418
        <xsl:attribute name="class">title</xsl:attribute>
419
419
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/MARC21slimUtils.xsl (-5 / +14 lines)
Lines 31-36 Link Here
31
		<xsl:param name="subdivDelimiter"/>
31
		<xsl:param name="subdivDelimiter"/>
32
        <xsl:param name="prefix"/>
32
        <xsl:param name="prefix"/>
33
        <xsl:param name="suffix"/>
33
        <xsl:param name="suffix"/>
34
        <xsl:param name="urlencode"/>
34
		<xsl:variable name="str">
35
		<xsl:variable name="str">
35
			<xsl:for-each select="marc:subfield">
36
			<xsl:for-each select="marc:subfield">
36
				<xsl:if test="contains($codes, @code)">
37
				<xsl:if test="contains($codes, @code)">
Lines 41-47 Link Here
41
				</xsl:if>
42
				</xsl:if>
42
			</xsl:for-each>
43
			</xsl:for-each>
43
		</xsl:variable>
44
		</xsl:variable>
44
		<xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/>
45
        <xsl:choose>
46
            <xsl:when test="$urlencode=1">
47
                <xsl:value-of select="str:encode-uri(substring($str,1,string-length($str)-string-length($delimeter)), true())"/>
48
            </xsl:when>
49
            <xsl:otherwise>
50
                <xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/>
51
            </xsl:otherwise>
52
        </xsl:choose>
45
	</xsl:template>
53
	</xsl:template>
46
54
47
    <xsl:template name="subfieldSelectSpan">
55
    <xsl:template name="subfieldSelectSpan">
Lines 114-129 Link Here
114
	     Assumes LOC convention: (OrgCode)recordNumber.
122
	     Assumes LOC convention: (OrgCode)recordNumber.
115
	     If OrgCode is not present, return full string.
123
	     If OrgCode is not present, return full string.
116
	     Additionally, handle various brackets/parentheses. Chop leading and trailing spaces.
124
	     Additionally, handle various brackets/parentheses. Chop leading and trailing spaces.
125
         Returns the value URI-encoded.
117
	-->
126
	-->
118
	<xsl:template name="extractControlNumber">
127
	<xsl:template name="extractControlNumber">
119
	    <xsl:param name="subfieldW"/>
128
	    <xsl:param name="subfieldW"/>
120
	    <xsl:variable name="tranW" select="translate($subfieldW,']})&gt;','))))')"/>
129
	    <xsl:variable name="tranW" select="translate($subfieldW,']})&gt;','))))')"/>
121
	    <xsl:choose>
130
	    <xsl:choose>
122
	      <xsl:when test="contains($tranW,')')">
131
	      <xsl:when test="contains($tranW,')')">
123
	        <xsl:value-of select="normalize-space(translate(substring-after($tranW,')'),'[]{}()&lt;&gt;',''))"/>
132
	        <xsl:value-of select="str:encode-uri(normalize-space(translate(substring-after($tranW,')'),'[]{}()&lt;&gt;','')), true())"/>
124
	      </xsl:when>
133
	      </xsl:when>
125
	      <xsl:otherwise>
134
	      <xsl:otherwise>
126
	        <xsl:value-of select="normalize-space($subfieldW)"/>
135
	        <xsl:value-of select="str:encode-uri(normalize-space($subfieldW), true())"/>
127
	      </xsl:otherwise>
136
	      </xsl:otherwise>
128
	    </xsl:choose>
137
	    </xsl:choose>
129
	</xsl:template>
138
	</xsl:template>
Lines 186-198 Link Here
186
                        <xsl:choose>
195
                        <xsl:choose>
187
                            <xsl:when test="boolean($bibno)">
196
                            <xsl:when test="boolean($bibno)">
188
                                <a>
197
                                <a>
189
                                    <xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of  select="$bibno"/></xsl:attribute>
198
                                    <xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of  select="str:encode-uri($bibno, true())"/></xsl:attribute>
190
                                    <xsl:value-of select="$str"/>
199
                                    <xsl:value-of select="$str"/>
191
                                </a>
200
                                </a>
192
                            </xsl:when>
201
                            </xsl:when>
193
                           <xsl:when test="boolean($index) and boolean(marc:subfield[@code=9])">
202
                           <xsl:when test="boolean($index) and boolean(marc:subfield[@code=9])">
194
                                <a>
203
                                <a>
195
                                    <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of  select="marc:subfield[@code=9]"/></xsl:attribute>
204
                                    <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of  select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
196
                                    <xsl:value-of select="$str"/>
205
                                    <xsl:value-of select="$str"/>
197
                                </a>
206
                                </a>
198
                            </xsl:when>
207
                            </xsl:when>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/NORMARCslim2OPACDetail.xsl (-9 / +9 lines)
Lines 101-107 Link Here
101
        <a>
101
        <a>
102
        <xsl:choose>
102
        <xsl:choose>
103
            <xsl:when test="marc:subfield[@code=9]">
103
            <xsl:when test="marc:subfield[@code=9]">
104
                <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
104
                <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
105
            </xsl:when>
105
            </xsl:when>
106
            <xsl:otherwise>
106
            <xsl:otherwise>
107
            <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
107
            <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
Lines 110-116 Link Here
110
        <xsl:call-template name="nameABCDQ"/></a>
110
        <xsl:call-template name="nameABCDQ"/></a>
111
        <xsl:if test="marc:subfield[@code=9]">
111
        <xsl:if test="marc:subfield[@code=9]">
112
            <a class='authlink'>
112
            <a class='authlink'>
113
                <xsl:attribute name="href">/cgi-bin/koha/opac-authoritiesdetail.pl?authid=<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
113
                <xsl:attribute name="href">/cgi-bin/koha/opac-authoritiesdetail.pl?authid=<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
114
                <xsl:element name="img">
114
                <xsl:element name="img">
115
                    <xsl:attribute name="src">/opac-tmpl/<xsl:value-of select="$theme"/>/images/filefind.png</xsl:attribute>
115
                    <xsl:attribute name="src">/opac-tmpl/<xsl:value-of select="$theme"/>/images/filefind.png</xsl:attribute>
116
                    <xsl:attribute name="style">vertical-align:middle</xsl:attribute>
116
                    <xsl:attribute name="style">vertical-align:middle</xsl:attribute>
Lines 127-133 Link Here
127
        <a>
127
        <a>
128
        <xsl:choose>
128
        <xsl:choose>
129
            <xsl:when test="marc:subfield[@code=9]">
129
            <xsl:when test="marc:subfield[@code=9]">
130
                <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
130
                <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
131
            </xsl:when>
131
            </xsl:when>
132
            <xsl:otherwise>
132
            <xsl:otherwise>
133
            <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
133
            <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
Lines 136-142 Link Here
136
        <xsl:call-template name="nameABCDN"/></a>
136
        <xsl:call-template name="nameABCDN"/></a>
137
        <xsl:if test="marc:subfield[@code=9]">
137
        <xsl:if test="marc:subfield[@code=9]">
138
            <a class='authlink'>
138
            <a class='authlink'>
139
                <xsl:attribute name="href">/cgi-bin/koha/opac-authoritiesdetail.pl?authid=<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
139
                <xsl:attribute name="href">/cgi-bin/koha/opac-authoritiesdetail.pl?authid=<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
140
                <xsl:element name="img">
140
                <xsl:element name="img">
141
                    <xsl:attribute name="src">/opac-tmpl/<xsl:value-of select="$theme"/>/images/filefind.png</xsl:attribute>
141
                    <xsl:attribute name="src">/opac-tmpl/<xsl:value-of select="$theme"/>/images/filefind.png</xsl:attribute>
142
                    <xsl:attribute name="style">vertical-align:middle</xsl:attribute>
142
                    <xsl:attribute name="style">vertical-align:middle</xsl:attribute>
Lines 152-158 Link Here
152
        <a>
152
        <a>
153
        <xsl:choose>
153
        <xsl:choose>
154
            <xsl:when test="marc:subfield[@code=9]">
154
            <xsl:when test="marc:subfield[@code=9]">
155
                <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
155
                <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
156
            </xsl:when>
156
            </xsl:when>
157
            <xsl:otherwise>
157
            <xsl:otherwise>
158
            <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
158
            <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=au:<xsl:value-of select="str:encode-uri(marc:subfield[@code='a'], true())"/></xsl:attribute>
Lines 161-167 Link Here
161
        <xsl:call-template name="nameACDEQ"/></a>
161
        <xsl:call-template name="nameACDEQ"/></a>
162
        <xsl:if test="marc:subfield[@code=9]">
162
        <xsl:if test="marc:subfield[@code=9]">
163
            <a class='authlink'>
163
            <a class='authlink'>
164
                <xsl:attribute name="href">/cgi-bin/koha/opac-authoritiesdetail.pl?authid=<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
164
                <xsl:attribute name="href">/cgi-bin/koha/opac-authoritiesdetail.pl?authid=<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
165
                <xsl:element name="img">
165
                <xsl:element name="img">
166
                    <xsl:attribute name="src">/opac-tmpl/<xsl:value-of select="$theme"/>/images/filefind.png</xsl:attribute>
166
                    <xsl:attribute name="src">/opac-tmpl/<xsl:value-of select="$theme"/>/images/filefind.png</xsl:attribute>
167
                    <xsl:attribute name="style">vertical-align:middle</xsl:attribute>
167
                    <xsl:attribute name="style">vertical-align:middle</xsl:attribute>
Lines 277-283 Link Here
277
                    <xsl:if test="marc:subfield[@code='g']"><xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='g']"/></xsl:if>
277
                    <xsl:if test="marc:subfield[@code='g']"><xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='g']"/></xsl:if>
278
                </xsl:when>
278
                </xsl:when>
279
                <xsl:when test="marc:subfield[@code='0']">
279
                <xsl:when test="marc:subfield[@code='0']">
280
                    <a><xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of select="marc:subfield[@code='0']"/></xsl:attribute>
280
                    <a><xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of select="str:encode-uri(marc:subfield[@code='0'], true())"/></xsl:attribute>
281
                        <xsl:value-of select="$f773"/>
281
                        <xsl:value-of select="$f773"/>
282
                    </a>
282
                    </a>
283
                </xsl:when>
283
                </xsl:when>
Lines 437-443 Link Here
437
            <xsl:choose>
437
            <xsl:choose>
438
            <!-- Will implement this later
438
            <!-- Will implement this later
439
                <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
439
                <xsl:when test="marc:subfield[@code=9] and $UseAuthoritiesForTracings='1'">
440
                    <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
440
                    <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
441
                </xsl:when>
441
                </xsl:when>
442
            -->
442
            -->
443
            <xsl:when test="$TraceSubjectSubdivisions='1'">
443
            <xsl:when test="$TraceSubjectSubdivisions='1'">
Lines 465-471 Link Here
465
            </a>
465
            </a>
466
            <xsl:if test="marc:subfield[@code=9]">
466
            <xsl:if test="marc:subfield[@code=9]">
467
                <a class='authlink'>
467
                <a class='authlink'>
468
                    <xsl:attribute name="href">/cgi-bin/koha/opac-authoritiesdetail.pl?authid=<xsl:value-of select="marc:subfield[@code=9]"/></xsl:attribute>
468
                    <xsl:attribute name="href">/cgi-bin/koha/opac-authoritiesdetail.pl?authid=<xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
469
                    <xsl:element name="img">
469
                    <xsl:element name="img">
470
                        <xsl:attribute name="src">/opac-tmpl/<xsl:value-of select="$theme"/>/images/filefind.png</xsl:attribute>
470
                        <xsl:attribute name="src">/opac-tmpl/<xsl:value-of select="$theme"/>/images/filefind.png</xsl:attribute>
471
                        <xsl:attribute name="style">vertical-align:middle</xsl:attribute>
471
                        <xsl:attribute name="style">vertical-align:middle</xsl:attribute>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/NORMARCslim2OPACResults.xsl (-2 / +2 lines)
Lines 299-305 Link Here
299
                    <xsl:value-of select="$BiblioDefaultView"/>
299
                    <xsl:value-of select="$BiblioDefaultView"/>
300
                </xsl:with-param>
300
                </xsl:with-param>
301
            </xsl:call-template>
301
            </xsl:call-template>
302
            <xsl:value-of select="$biblionumber"/>
302
            <xsl:value-of select="str:encode-uri($biblionumber, true())"/>
303
        </xsl:attribute>
303
        </xsl:attribute>
304
        <xsl:attribute name="class">title</xsl:attribute>
304
        <xsl:attribute name="class">title</xsl:attribute>
305
305
Lines 436-442 Link Here
436
                    <xsl:if test="marc:subfield[@code='g']"><xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='g']"/></xsl:if>
436
                    <xsl:if test="marc:subfield[@code='g']"><xsl:text> </xsl:text><xsl:value-of select="marc:subfield[@code='g']"/></xsl:if>
437
                </xsl:when>
437
                </xsl:when>
438
                <xsl:when test="marc:subfield[@code='0']">
438
                <xsl:when test="marc:subfield[@code='0']">
439
                    <a><xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of select="marc:subfield[@code='0']"/></xsl:attribute>
439
                    <a><xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of select="str:encode-uri(marc:subfield[@code='0'], true())"/></xsl:attribute>
440
                        <xsl:value-of select="$f773"/>
440
                        <xsl:value-of select="$f773"/>
441
                    </a>
441
                    </a>
442
                </xsl:when>
442
                </xsl:when>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/NORMARCslimUtils.xsl (-5 / +14 lines)
Lines 31-36 Link Here
31
		<xsl:param name="subdivDelimiter"/>
31
		<xsl:param name="subdivDelimiter"/>
32
        <xsl:param name="prefix"/>
32
        <xsl:param name="prefix"/>
33
        <xsl:param name="suffix"/>
33
        <xsl:param name="suffix"/>
34
        <xsl:param name="urlencode"/>
34
		<xsl:variable name="str">
35
		<xsl:variable name="str">
35
			<xsl:for-each select="marc:subfield">
36
			<xsl:for-each select="marc:subfield">
36
				<xsl:if test="contains($codes, @code)">
37
				<xsl:if test="contains($codes, @code)">
Lines 41-47 Link Here
41
				</xsl:if>
42
				</xsl:if>
42
			</xsl:for-each>
43
			</xsl:for-each>
43
		</xsl:variable>
44
		</xsl:variable>
44
		<xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/>
45
        <xsl:choose>
46
            <xsl:when test="$urlencode=1">
47
                <xsl:value-of select="str:encode-uri(substring($str,1,string-length($str)-string-length($delimeter)), true())"/>
48
            </xsl:when>
49
            <xsl:otherwise>
50
                <xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/>
51
            </xsl:otherwise>
52
        </xsl:choose>
45
	</xsl:template>
53
	</xsl:template>
46
54
47
	<xsl:template name="buildSpaces">
55
	<xsl:template name="buildSpaces">
Lines 95-110 Link Here
95
	     Assumes LOC convention: (OrgCode)recordNumber.
103
	     Assumes LOC convention: (OrgCode)recordNumber.
96
	     If OrgCode is not present, return full string.
104
	     If OrgCode is not present, return full string.
97
	     Additionally, handle various brackets/parentheses. Chop leading and trailing spaces.
105
	     Additionally, handle various brackets/parentheses. Chop leading and trailing spaces.
106
         Returns the value URI-encoded.
98
	-->
107
	-->
99
	<xsl:template name="extractControlNumber">
108
	<xsl:template name="extractControlNumber">
100
	    <xsl:param name="subfieldW"/>
109
	    <xsl:param name="subfieldW"/>
101
	    <xsl:variable name="tranW" select="translate($subfieldW,']})&gt;','))))')"/>
110
	    <xsl:variable name="tranW" select="translate($subfieldW,']})&gt;','))))')"/>
102
	    <xsl:choose>
111
	    <xsl:choose>
103
	      <xsl:when test="contains($tranW,')')">
112
	      <xsl:when test="contains($tranW,')')">
104
	        <xsl:value-of select="normalize-space(translate(substring-after($tranW,')'),'[]{}()&lt;&gt;',''))"/>
113
	        <xsl:value-of select="str:encode-uri(normalize-space(translate(substring-after($tranW,')'),'[]{}()&lt;&gt;','')), true())"/>
105
	      </xsl:when>
114
	      </xsl:when>
106
	      <xsl:otherwise>
115
	      <xsl:otherwise>
107
	        <xsl:value-of select="normalize-space($subfieldW)"/>
116
	        <xsl:value-of select="str:encode-uri(normalize-space($subfieldW), true())"/>
108
	      </xsl:otherwise>
117
	      </xsl:otherwise>
109
	    </xsl:choose>
118
	    </xsl:choose>
110
	</xsl:template>
119
	</xsl:template>
Lines 215-227 Link Here
215
                        <xsl:choose>
224
                        <xsl:choose>
216
                            <xsl:when test="boolean($bibno)">
225
                            <xsl:when test="boolean($bibno)">
217
                                <a>
226
                                <a>
218
                                    <xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of  select="$bibno"/></xsl:attribute>
227
                                    <xsl:attribute name="href">/cgi-bin/koha/opac-detail.pl?biblionumber=<xsl:value-of  select="str:encode-uri($bibno, true())"/></xsl:attribute>
219
                                    <xsl:value-of select="$str"/>
228
                                    <xsl:value-of select="$str"/>
220
                                </a>
229
                                </a>
221
                            </xsl:when>
230
                            </xsl:when>
222
                           <xsl:when test="boolean($index) and boolean(marc:subfield[@code=9])">
231
                           <xsl:when test="boolean($index) and boolean(marc:subfield[@code=9])">
223
                                <a>
232
                                <a>
224
                                    <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of  select="marc:subfield[@code=9]"/></xsl:attribute>
233
                                    <xsl:attribute name="href">/cgi-bin/koha/opac-search.pl?q=an:<xsl:value-of  select="str:encode-uri(marc:subfield[@code=9], true())"/></xsl:attribute>
225
                                    <xsl:value-of select="$str"/>
234
                                    <xsl:value-of select="$str"/>
226
                                </a>
235
                                </a>
227
                            </xsl:when>
236
                            </xsl:when>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslim2OPACResults.xsl (-1 / +1 lines)
Lines 48-54 Link Here
48
                          <xsl:value-of select="$BiblioDefaultView"/>
48
                          <xsl:value-of select="$BiblioDefaultView"/>
49
                      </xsl:with-param>
49
                      </xsl:with-param>
50
                  </xsl:call-template>
50
                  </xsl:call-template>
51
                  <xsl:value-of select="$biblionumber"/>
51
                  <xsl:value-of select="str:encode-uri($biblionumber, true())"/>
52
                </xsl:attribute>
52
                </xsl:attribute>
53
                <xsl:attribute name="class">title</xsl:attribute>
53
                <xsl:attribute name="class">title</xsl:attribute>
54
                <xsl:value-of select="$ntitle" />
54
                <xsl:value-of select="$ntitle" />
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/xslt/UNIMARCslimUtils.xsl (-5 / +12 lines)
Lines 33-38 Link Here
33
    <xsl:param name="delimeter"><xsl:text> </xsl:text></xsl:param>
33
    <xsl:param name="delimeter"><xsl:text> </xsl:text></xsl:param>
34
    <xsl:param name="subdivCodes"/>
34
    <xsl:param name="subdivCodes"/>
35
    <xsl:param name="subdivDelimiter"/>
35
    <xsl:param name="subdivDelimiter"/>
36
    <xsl:param name="urlencode"/>
36
    <xsl:variable name="str">
37
    <xsl:variable name="str">
37
      <xsl:for-each select="marc:subfield">
38
      <xsl:for-each select="marc:subfield">
38
        <xsl:if test="contains($codes, @code)">
39
        <xsl:if test="contains($codes, @code)">
Lines 43-49 Link Here
43
        </xsl:if>
44
        </xsl:if>
44
      </xsl:for-each>
45
      </xsl:for-each>
45
    </xsl:variable>
46
    </xsl:variable>
46
    <xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/>
47
    <xsl:choose>
48
      <xsl:when test="$urlencode=1">
49
        <xsl:value-of select="str:encode-uri(substring($str,1,string-length($str)-string-length($delimeter)), true())"/>
50
      </xsl:when>
51
      <xsl:otherwise>
52
        <xsl:value-of select="substring($str,1,string-length($str)-string-length($delimeter))"/>
53
      </xsl:otherwise>
54
    </xsl:choose>
47
  </xsl:template>
55
  </xsl:template>
48
56
49
  <xsl:template name="buildSpaces">
57
  <xsl:template name="buildSpaces">
Lines 265-271 Link Here
265
            <a>
273
            <a>
266
              <xsl:attribute name="href">
274
              <xsl:attribute name="href">
267
                <xsl:text>/cgi-bin/koha/opac-search.pl?q=an:</xsl:text>
275
                <xsl:text>/cgi-bin/koha/opac-search.pl?q=an:</xsl:text>
268
                <xsl:value-of select="."/>
276
                <xsl:value-of select="str:encode-uri(., true())"/>
269
              </xsl:attribute>
277
              </xsl:attribute>
270
              <xsl:choose>
278
              <xsl:choose>
271
                <xsl:when test="string-length($display) &gt; 0">
279
                <xsl:when test="string-length($display) &gt; 0">
Lines 350-356 Link Here
350
                <xsl:when test="marc:subfield[@code=9]">
358
                <xsl:when test="marc:subfield[@code=9]">
351
                  <xsl:attribute name="href">
359
                  <xsl:attribute name="href">
352
                    <xsl:text>/cgi-bin/koha/opac-search.pl?q=an:</xsl:text>
360
                    <xsl:text>/cgi-bin/koha/opac-search.pl?q=an:</xsl:text>
353
                    <xsl:value-of select="marc:subfield[@code=9]"/>
361
                    <xsl:value-of select="str:encode-uri(marc:subfield[@code=9], true())"/>
354
                  </xsl:attribute>
362
                  </xsl:attribute>
355
                </xsl:when>
363
                </xsl:when>
356
                <xsl:otherwise>
364
                <xsl:otherwise>
Lines 381-387 Link Here
381
                <a>
389
                <a>
382
                  <xsl:attribute name="href">
390
                  <xsl:attribute name="href">
383
                    <xsl:text>/cgi-bin/koha/opac-idref.pl?unimarc3=</xsl:text>
391
                    <xsl:text>/cgi-bin/koha/opac-idref.pl?unimarc3=</xsl:text>
384
                    <xsl:value-of select="marc:subfield[@code=3]"/>
392
                    <xsl:value-of select="str:encode-uri(marc:subfield[@code=3], true())"/>
385
                  </xsl:attribute>
393
                  </xsl:attribute>
386
                  <xsl:attribute name="title">IdRef</xsl:attribute>
394
                  <xsl:attribute name="title">IdRef</xsl:attribute>
387
                  <xsl:attribute name="rel">gb_page_center[600,500]</xsl:attribute>
395
                  <xsl:attribute name="rel">gb_page_center[600,500]</xsl:attribute>
388
- 

Return to bug 14716