+[% USE raw %]
[% USE Asset %]
[% USE Branches %]
[% USE HtmlTags %]
[% INCLUDE 'doc-head-open.inc' %]
<title>Koha › Administration › Library OverDrive Info ›</title>
[% INCLUDE 'doc-head-close.inc' %]
-[% Asset.css("css/datatables.css") %]
+[% Asset.css("css/datatables.css") | $raw %]
</head>
<body id="admin_overdrive" class="admin">
[% FOREACH b IN branches %]
<tr>
<td>
- [% Branches.GetName( b.branchcode ) %]
- <input type="hidden" name="branchcode" value="[% b.branchcode %]" />
+ [% Branches.GetName( b.branchcode ) | html %]
+ <input type="hidden" name="branchcode" value="[% b.branchcode | html %]" />
</td>
<td>
- <input type="text" name="authname" value="[% b.authname %]" />
+ <input type="text" name="authname" value="[% b.authname | html %]" />
</td>
</tr>
[% END %]
</div>
[% MACRO jsinclude BLOCK %]
- [% Asset.js("js/admin-menu.js") %]
+ [% Asset.js("js/admin-menu.js") | $raw %]
[% INCLUDE 'datatables.inc' %]
[% INCLUDE 'columns_settings.inc' %]
<script type="text/javascript">
$action eq 'login' && do {
my $password = $cgi->param("password") // q{} ;
my $patron = Koha::Patrons->find({ userid => $user });
- my $branch_info = Koha::Library::OverDriveInfos->find( $patron->branchcode ) if $patron;
- my $branch_authname = $branch_info->authname if $branch_info;
+ my $branch_info = $patron ? Koha::Library::OverDriveInfos->find( $patron->branchcode ) : undef;
+ my $branch_authname = $branch_info ? $branch_info->authname : undef;
my $authname = $branch_authname || C4::Context->preference('OverDriveAuthname');
$od->auth_by_userid($user, $password,C4::Context->preference('OverDriveWebsiteID'),$authname);
$data{login_success} = 1;