Bug 16095: Remove target="_blank" when a link refer to an external link
[koha.git] / koha-tmpl / opac-tmpl / bootstrap / en / modules / opac-idref.tt
1 [% INCLUDE 'doc-head-open.inc' %]
2 <title>[% IF ( LibraryNameTitle ) %][% LibraryNameTitle %][% ELSE %]Koha online[% END %] catalog &rsaquo; Your search IDREF for ppn [% unimarc3 %]</title>
3 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
4 [% INCLUDE 'doc-head-close.inc' popup => 1 %]
5 [% BLOCK cssinclude %]
6   <style type="text/css">
7     ul.ui-tabs-nav li a, ul.ui-tabs-nav li span.a  { padding:0.6em 1em; }
8     #idref h2.role {
9         background-color: #DDDEEE;
10         cursor: pointer;
11     }
12     #idref table {
13         margin: 0;
14     }
15   </style>
16 [% END %]
17
18 </head>
19 [% INCLUDE 'bodytag.inc' bodyid='idref' bodyclass='scrollto' %]
20 <div class="main">
21   [% IF error %]
22     This ppn is not found on the idref service.
23   [% ELSE %]
24     [% FOREACH role IN content %]
25       <div>
26         <h2 class="role" title="Click to expand this role">[% role.role_name %] ([% role.count %])</h2>
27           <div class="docs">
28             <table>
29               <thead>
30                 <th>Citation</th>
31                 <th>Koha</th>
32                 <th>Sudoc</th>
33               </thead>
34               <tbody>
35                 [% FOREACH doc IN role.docs %]
36                   <tr>
37                     <td>[% doc.citation %]</td>
38                     <td><a href="/cgi-bin/koha/opac-search.pl?q=ident:[% doc.ppn %]" target="_blank">Koha</a></td>
39                     <td><a href="http://www.sudoc.fr/[% doc.ppn %]" target="_blank" rel="noreferrer">Sudoc</a></td>
40                   </tr>
41                 [% END %]
42               </tbody>
43             </table>
44           </div>
45       </div>
46     [% END %]
47   [% END %]
48 </div>
49 [% BLOCK jsinclude %]
50 [% INCLUDE 'datatables.inc' %]
51 <script type="text/javascript">
52   $(document).ready(function (){
53       $("table").dataTable($.extend(true, {}, dataTablesDefaults, {
54           'bFilter': false,
55           'aoColumnDefs': [
56               { 'aTargets': [-1, -2], 'bSortable': false }
57           ],
58       }));
59
60       $(".role").click(function(){
61           var docs_node = $(this).parent().find("div.docs");
62           if ( $(docs_node).is(":visible") ) {
63               $(".docs").hide();
64           } else {
65               $(".docs").hide();
66               docs_node.show();
67           }
68       });
69       $(".docs").hide();
70   });
71 </script>
72 [% END %]
73
74 [% INCLUDE 'opac-bottom.inc' is_popup=1%]