Bugzilla – Attachment 156247 Details for
Bug 34865
Syspref OPACURLOpenInNewWindow not working for Library URLs
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 34865: Use OPACURLOpenInNewWindow for library URLs
Bug-34865-Use-OPACURLOpenInNewWindow-for-library-U.patch (text/plain), 1.88 KB, created by
Lucas Gass (lukeg)
on 2023-09-26 20:48:44 UTC
(
hide
)
Description:
Bug 34865: Use OPACURLOpenInNewWindow for library URLs
Filename:
MIME Type:
Creator:
Lucas Gass (lukeg)
Created:
2023-09-26 20:48:44 UTC
Size:
1.88 KB
patch
obsolete
>From bb302360ec89772697dccbd6f986fcddbc122521 Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Mon, 25 Sep 2023 12:46:08 +0000 >Subject: [PATCH] Bug 34865: Use OPACURLOpenInNewWindow for library URLs > >If a library has a URL defined it is shown in the OPAC under the >libraries page. This patch updates the template so that the link >respects the OPACURLOpenInNewWindow system preference. > >To test, apply the patch and go to Administration -> Libraries and edit >a library if necessary so that it has a URL defined. > >In the OPAC, go to the Libraries page. Test that the library link >respects whichever setting you have for OPACURLOpenInNewWindow > >Signed-off-by: Kelly McElligott <kelly@bywatersolutions.com> >Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> >--- > koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-library.tt | 6 +++++- > 1 file changed, 5 insertions(+), 1 deletion(-) > >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-library.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-library.tt >index 4a5fef45c7..508af182e0 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-library.tt >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-library.tt >@@ -52,7 +52,11 @@ > <p class="branchfax">Fax: <span property="faxNumber">[% library.branchfax | html %]</span></p> > [% END %] > [% IF ( library.branchurl ) %] >- <p class="branchurl"><a href="[% library.branchurl | url %]" property="url">[% library.branchurl | html %]</a></p> >+ [% IF ( Koha.Preference('OPACURLOpenInNewWindow') ) %] >+ <p class="branchurl"><a href="[% library.branchurl | url %]" target="_blank" rel="noreferrer" property="url">[% library.branchurl | html %]</a></p> >+ [% ELSE %] >+ <p class="branchurl"><a href="[% library.branchurl | url %]" property="url">[% library.branchurl | html %]</a></p> >+ [% END %] > [% END %] > [% END %] > >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 34865
:
156165
|
156228
| 156247