Bugzilla – Attachment 69131 Details for
Bug 19456
Some pages title tag contains html
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 19456: Make patron-title ability to be generated with or without html tags
Bug-19456-Make-patron-title-ability-to-be-generate.patch (text/plain), 12.99 KB, created by
Nick Clemens (kidclamp)
on 2017-11-13 16:54:02 UTC
(
hide
)
Description:
Bug 19456: Make patron-title ability to be generated with or without html tags
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2017-11-13 16:54:02 UTC
Size:
12.99 KB
patch
obsolete
>From dda156161c0fd68826f2000bb86988654c06ae50 Mon Sep 17 00:00:00 2001 >From: Josef Moravec <josef.moravec@gmail.com> >Date: Fri, 13 Oct 2017 06:44:55 +0000 >Subject: [PATCH] Bug 19456: Make patron-title ability to be generated with or > without html tags > >Modified pages: >circ/circulation.pl >circ/circulation_batch_checkouts.pl >members/boraccount.pl >members/files.pl >members/holdshistory.pl >members/housebound.pl >members/moremember.pl >members/notices.pl >members/purchase-suggestions.pl >members/readingrec.pl >members/routing-lists.pl >members/statistics.pl > >Test plan: >0) Do not apply the patch >1) Have a patron with title/salution filled in >2) Confirm bug, go for example to circ/circulation page and see there is >html in <title> tag (you can see it in your browser page/window title) >3) Apply the patch >4) Go through circulation/patron pages (see modified page above) and >confirm there is no html in <title> tag, but on the page itself the >salutation should be in <span class="patron-title"> > >Signed-off-by: David Bourgalt <david.bourgault@inlibro.com> > >Signed-off-by: Nick Clemens <nick@bywatersolutions.com> >--- > .../intranet-tmpl/prog/en/includes/patron-title.inc | 16 ++++++++++++---- > .../intranet-tmpl/prog/en/modules/circ/circulation.tt | 2 +- > .../prog/en/modules/circ/circulation_batch_checkouts.tt | 2 +- > .../intranet-tmpl/prog/en/modules/members/boraccount.tt | 2 +- > koha-tmpl/intranet-tmpl/prog/en/modules/members/files.tt | 2 +- > .../prog/en/modules/members/holdshistory.tt | 2 +- > .../intranet-tmpl/prog/en/modules/members/housebound.tt | 2 +- > .../intranet-tmpl/prog/en/modules/members/moremember.tt | 2 +- > .../intranet-tmpl/prog/en/modules/members/notices.tt | 2 +- > .../prog/en/modules/members/purchase-suggestions.tt | 2 +- > .../intranet-tmpl/prog/en/modules/members/readingrec.tt | 2 +- > .../prog/en/modules/members/routing-lists.tt | 2 +- > .../intranet-tmpl/prog/en/modules/members/statistics.tt | 2 +- > 13 files changed, 24 insertions(+), 16 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-title.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/patron-title.inc >index c7818f0..6600032 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-title.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/patron-title.inc >@@ -1,11 +1,19 @@ >+[%# Parameter no_html - if 1, the html tags are NOT generated %] >+[%- IF no_html %] >+ [%- span_start = '' %] >+ [%- span_end = '' %] >+[%- ELSE %] >+ [%- span_start = '<span class="patron-title">' %] >+ [%- span_end = '</span>' %] >+[%- END %] > [%- IF ( borrower.borrowernumber ) %] > [%- IF borrower.category_type == 'I' %] > [%- borrower.surname | html %] [% IF borrower.othernames %] ([% borrower.othernames | html %]) [% END %] > [%- ELSE %] > [%- IF invert_name %] >- [%- IF borrower.title %]<span class="patron-title">[%- borrower.title | html %]</span> [% END %][%- borrower.surname | html %], [% borrower.firstname | html %] [% IF borrower.othernames %] ([% borrower.othernames | html %]) [% END %] >+ [%- IF borrower.title %][% span_start %][%- borrower.title | html %][% span_end %] [% END %][%- borrower.surname | html %], [% borrower.firstname | html %] [% IF borrower.othernames %] ([% borrower.othernames | html %]) [% END %] > [%- ELSE %] >- [%- IF borrower.title %]<span class="patron-title">[%- borrower.title | html %]</span> [% END %][%- borrower.firstname | html %] [% IF borrower.othernames %] ([% borrower.othernames | html %]) [% END %] [% borrower.surname | html %] >+ [%- IF borrower.title %][% span_start %][%- borrower.title | html %][% span_end %] [% END %][%- borrower.firstname | html %] [% IF borrower.othernames %] ([% borrower.othernames | html %]) [% END %] [% borrower.surname | html %] > [%- END -%] > [%- END -%] > [%- IF ( borrower.cardnumber ) -%] >@@ -16,9 +24,9 @@ > [%- surname | html %] [% IF othernames %] ([% othernames | html %]) [% END %] > [%- ELSE %] > [%- IF invert_name %] >- [%- IF title %]<span class="patron-title">[%- title | html %]</span> [% END %][%- surname | html %], [% firstname | html %] [% IF othernames %] ([% othernames | html %]) [% END %] >+ [%- IF title %][% span_start %][%- title | html %][% span_end %] [% END %][%- surname | html %], [% firstname | html %] [% IF othernames %] ([% othernames | html %]) [% END %] > [%- ELSE %] >- [%- IF title %]<span class="patron-title">[%- title | html %]</span> [% END %][%- firstname | html %] [% IF othernames %] ([% othernames | html %]) [% END %] [% surname | html %] >+ [%- IF title %][% span_start %][%- title | html %][% span_end %] [% END %][%- firstname | html %] [% IF othernames %] ([% othernames | html %]) [% END %] [% surname | html %] > [%- END %] > [%- END -%] > [%- IF ( cardnumber ) -%] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt >index d5507c0..842e479 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt >@@ -10,7 +10,7 @@ > [% SET destination = "circ" %] > <title>Koha › Circulation > [% IF borrowernumber and borrower%] >- › Checking out to [% INCLUDE 'patron-title.inc' invert_name = 1 %] >+ › Checking out to [% INCLUDE 'patron-title.inc' invert_name = 1 no_html = 1 %] > [% END %] > </title> > [% INCLUDE 'doc-head-close.inc' %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation_batch_checkouts.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation_batch_checkouts.tt >index 1fc917f..2416f36 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation_batch_checkouts.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation_batch_checkouts.tt >@@ -6,7 +6,7 @@ > [% SET destination = "circ" %] > <title>Koha › Circulation > [% IF borrowernumber and borrower %] >- › Batch check out › Issuing items to [% INCLUDE 'patron-title.inc' invert_name = 1 %] >+ › Batch check out › Issuing items to [% INCLUDE 'patron-title.inc' invert_name = 1 no_html = 1 %] > [% END %] > </title> > [% INCLUDE 'doc-head-close.inc' %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt >index ef4354a..efcc726 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt >@@ -3,7 +3,7 @@ > [% USE ColumnsSettings %] > [% USE Price %] > [% INCLUDE 'doc-head-open.inc' %] >-<title>Koha › Patrons › Account for [% INCLUDE 'patron-title.inc' %]</title> >+<title>Koha › Patrons › Account for [% INCLUDE 'patron-title.inc' no_html = 1 %]</title> > [% INCLUDE 'doc-head-close.inc' %] > <link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/datatables.css" /> > [% INCLUDE 'datatables.inc' %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/files.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/files.tt >index ba4cc1f..b5cf108 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/files.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/files.tt >@@ -1,7 +1,7 @@ > [% USE KohaDates %] > [% USE AuthorisedValues %] > [% INCLUDE 'doc-head-open.inc' %] >-<title>Files for [% INCLUDE 'patron-title.inc' %]</title> >+<title>Files for [% INCLUDE 'patron-title.inc' no_html = 1 %]</title> > [% INCLUDE 'doc-head-close.inc' %] > <script type="text/javascript"> > $(document).ready(function(){ >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt >index 811c545..0a93647 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt >@@ -4,7 +4,7 @@ > [% USE Branches %] > [% USE ColumnsSettings %] > [% INCLUDE 'doc-head-open.inc' %] >-<title>Holds history for [% INCLUDE 'patron-title.inc' %]</title> >+<title>Holds history for [% INCLUDE 'patron-title.inc' no_html = 1 %]</title> > [% INCLUDE 'doc-head-close.inc' %] > <link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/datatables.css" /> > [% INCLUDE 'datatables.inc' %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/housebound.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/housebound.tt >index c17363f..e754a31 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/housebound.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/housebound.tt >@@ -2,7 +2,7 @@ > [% USE KohaDates %] > [% USE AuthorisedValues %] > [% INCLUDE 'doc-head-open.inc' %] >-<title>Koha › Housebound › Details for [% INCLUDE 'patron-title.inc' %]</title> >+<title>Koha › Housebound › Details for [% INCLUDE 'patron-title.inc' no_html = 1 %]</title> > [% INCLUDE 'doc-head-close.inc' %] > [% INCLUDE 'calendar.inc' %] > <script type="text/javascript"> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt >index b40c29a..83e964a 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt >@@ -8,7 +8,7 @@ > [% IF ( unknowuser ) %] > Patron does not exist > [% ELSE %] >- Patron details for [% INCLUDE 'patron-title.inc' %] >+ Patron details for [% INCLUDE 'patron-title.inc' no_html = 1 %] > [% END %] > </title> > [% INCLUDE 'doc-head-close.inc' %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/notices.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/notices.tt >index 7ae818c..465936c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/notices.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/notices.tt >@@ -3,7 +3,7 @@ > [% USE Branches %] > [% USE KohaDates %] > [% INCLUDE 'doc-head-open.inc' %] >-<title>Sent notices for [% INCLUDE 'patron-title.inc' %]</title> >+<title>Sent notices for [% INCLUDE 'patron-title.inc' no_html = 1 %]</title> > [% INCLUDE 'doc-head-close.inc' %] > <link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/datatables.css" /> > [% INCLUDE 'datatables.inc' %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/purchase-suggestions.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/purchase-suggestions.tt >index a6f1e8f..0f06a53 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/purchase-suggestions.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/purchase-suggestions.tt >@@ -2,7 +2,7 @@ > [% USE AuthorisedValues %] > [% USE Branches %] > [% INCLUDE 'doc-head-open.inc' %] >-<title>Koha › Patrons › Purchase suggestions for [% INCLUDE 'patron-title.inc' %]</title> >+<title>Koha › Patrons › Purchase suggestions for [% INCLUDE 'patron-title.inc' no_html = 1 %]</title> > <link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/datatables.css" /> > [% INCLUDE 'doc-head-close.inc' %] > [% INCLUDE 'datatables.inc' %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/readingrec.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/readingrec.tt >index 5f2e1d8..5a66af3 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/readingrec.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/readingrec.tt >@@ -3,7 +3,7 @@ > [% USE AuthorisedValues %] > [% USE Branches %] > [% INCLUDE 'doc-head-open.inc' %] >-<title>Circulation History for [% INCLUDE 'patron-title.inc' %]</title> >+<title>Circulation History for [% INCLUDE 'patron-title.inc' no_html = 1 %]</title> > [% INCLUDE 'doc-head-close.inc' %] > <link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/datatables.css" /> > [% INCLUDE 'datatables.inc' %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/routing-lists.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/routing-lists.tt >index be6d0ef..8fadc2b 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/routing-lists.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/routing-lists.tt >@@ -2,7 +2,7 @@ > [% USE AuthorisedValues %] > [% USE Branches %] > [% INCLUDE 'doc-head-open.inc' %] >-<title>Subscription Routing Lists for [% INCLUDE 'patron-title.inc' %]</title> >+<title>Subscription Routing Lists for [% INCLUDE 'patron-title.inc' no_html = 1 %]</title> > [% INCLUDE 'doc-head-close.inc' %] > </head> > <body id="pat_routing_lists" class="pat"> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/statistics.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/statistics.tt >index 44a0bca..cab85c0 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/statistics.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/statistics.tt >@@ -3,7 +3,7 @@ > [% USE Branches %] > [% INCLUDE 'doc-head-open.inc' %] > <title>Koha › Patrons › >-Statistics for [% INCLUDE 'patron-title.inc' %] >+Statistics for [% INCLUDE 'patron-title.inc' no_html = 1 %] > </title> > [% INCLUDE 'doc-head-close.inc' %] > <link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/datatables.css" /> >-- >2.1.4
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 19456
:
68044
|
68081
|
68702
|
68787
|
68790
| 69131