Bug 13609: Patch for 3.16.x and 3.14.x (3.16.x needs both, 3.14.x just this)
authorChris Cormack <chrisc@catalyst.net.nz>
Thu, 22 Jan 2015 19:43:14 +0000 (08:43 +1300)
committerFridolin Somers <fridolin.somers@biblibre.com>
Fri, 23 Jan 2015 09:28:22 +0000 (10:28 +0100)
To Test:

- Use an installation a reasonable amount of authorities, so that you
  can have a search result list with more than one page
- Activate OpacAuthorities
- Create an OPAC link like shown below, verify that an alert is shown
- Apply patch
- Refresh the page and no alert should appear
- Verify the paging still works correctly for 'numbers' and 'arrows'

URL: .../cgi-bin/koha/opac-authorities-home.pl?and_or=and&marclist=match&op=do_search&operator=contains&orderby=HeadingAsc2"><script>prompt(987898)</script>

Signed-off-by: Mason James <mtj@kohaaloha.com>
(cherry picked from commit 20dd347c4866226e29c4bbeeebf66a33f347302a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>

koha-tmpl/opac-tmpl/prog/en/modules/opac-authoritiessearchresultlist.tt

index 7f80fe0..43e835f 100644 (file)
@@ -15,7 +15,7 @@
        <h1>Authority search results</h1>
        <div id="pages">
                        [% IF ( displayprev ) %]
-                               <a href="opac-authorities-home.pl?startfrom=[% startfromprev %]&amp;[% FOREACH searchdat IN searchdata %][% searchdat.term %]=[% searchdat.val |url %]&amp;[% END %]resultsperpage=[% resultsperpage %]&amp;type=opac&amp;op=do_search&amp;authtypecode=[% authtypecode %]&amp;orderby=[% orderby %]">
+                               <a href="opac-authorities-home.pl?startfrom=[% startfromprev %]&amp;[% FOREACH searchdat IN searchdata %][% searchdat.term %]=[% searchdat.val |url %]&amp;[% END %]resultsperpage=[% resultsperpage %]&amp;type=opac&amp;op=do_search&amp;authtypecode=[% authtypecode %]&amp;orderby=[% orderby | html%]">
                                        &lt;&lt;
                                </a>
                        [% END %]
                                [% IF ( number.highlight ) %]
                                        <span class="current">[% number.number %]</span>
                                [% ELSE %]
-                                       <a href="opac-authorities-home.pl?startfrom=[% number.startfrom %]&amp;[% FOREACH searchdat IN number.searchdata %][% searchdat.term %]=[% searchdat.val |url %]&amp;[% END %]resultsperpage=[% resultsperpage %]&amp;type=opac&amp;op=do_search&amp;authtypecode=[% authtypecode %]&amp;orderby=[% orderby %]">[% number.number %]</a>
+                                       <a href="opac-authorities-home.pl?startfrom=[% number.startfrom %]&amp;[% FOREACH searchdat IN number.searchdata %][% searchdat.term %]=[% searchdat.val |url %]&amp;[% END %]resultsperpage=[% resultsperpage %]&amp;type=opac&amp;op=do_search&amp;authtypecode=[% authtypecode %]&amp;orderby=[% orderby |html %]">[% number.number %]</a>
                                [% END %]
                        [% END %]
                        [% IF ( displaynext ) %]
-                               <a href="opac-authorities-home.pl?startfrom=[% startfromnext %]&amp;[% FOREACH searchdat IN searchdata %][% searchdat.term %]=[% searchdat.val |url %]&amp;[% END %]&amp;resultsperpage=[% resultsperpage %]&amp;type=opac&amp;op=do_search&amp;authtypecode=[% authtypecode %]&amp;orderby=[% orderby %]">&gt;&gt;</a>
+                               <a href="opac-authorities-home.pl?startfrom=[% startfromnext %]&amp;[% FOREACH searchdat IN searchdata %][% searchdat.term %]=[% searchdat.val |url %]&amp;[% END %]&amp;resultsperpage=[% resultsperpage %]&amp;type=opac&amp;op=do_search&amp;authtypecode=[% authtypecode %]&amp;orderby=[% orderby |html%]">&gt;&gt;</a>
                                [% END %]
                </div>
                <div id="results">