In the "Alert subscriptions" tab in the OPAC there is broken HTML showing on the page, maybe from a merge conflict, because it doesn't actually make sense, to display the name in that spot. To test: * Add a serial subscription and set a notification template * Go to the OPAC and subscribe to the email notification for this subscription (you must be logged in to see the button on the subscriptions tab) * Go to the patron account > tab alert subscriptions * Verify in the last column something like this shows: Frau Karin Mustermann"> X Unsubscribe from email alerts The "Frau Karin Mustermann">" should not be there.
In order to reproduce this: Make sure you are testing with a user, that has a salutation, surname and firstname set. The problem is patroninfo creating HTML tags even with the no_html flag set it looks like: <form action="/cgi-bin/koha/opac-alert-subscribe.pl" method="post" class="unsubscribe" data-title="[% sub.biblio.title | html %] [% sub.biblio.subtitle | html %]" data-patron="[% INCLUDE 'patron-title.inc' no_html=1 patron=logged_in_user%]"> Generates: <form action="/cgi-bin/koha/opac-alert-subscribe.pl" method="post" class="unsubscribe" data-title="Kölner Zeitschrift für Soziologie und Sozialpsychologie, " data-patron=" <span class="patron-title">Frau</span> Karin Mustermann"> ... Which is invalid because of the "" and also there should be NO HTML tags.
Hm, OK; there is no no_html flag for patron_title.inc in the OPAC: https://git.koha-community.org/Koha-community/Koha/src/commit/5832521086b06c2221474791278ebd9b5bdb4049/koha-tmpl/opac-tmpl/bootstrap/en/includes/patron-title.inc
I've temporarily switched to [% logged_in_user.firstname %] [% logged_in_user.surname %] which seems to avoid the issue for now. Just switching the " for ' leaves a broken confirmation message. I think we need to implement a no_html flag for patron_title.inc in the OPAC to properly fix this.
Created attachment 185746 [details] [review] Bug 40602: Broken HTML showing in Alert 'subscriptions' tab This patch adds handling of the "no-html" flag to patron-title.inc. The OPAC alert subscriptions page passes the "no-html" flag but the include file wasn't written to include it. To test, apply the patch and log in to the OPAC as a user who has a title (salutation). - Add a serial subscription and set a notification template - Go to the OPAC and subscribe to the email notification for this subscription - Go to the patron account > Alert subscriptions tab - Verify that the last column shows an "Unsubscribe from email alerts" button. - There should be no errant HTML. Sponsored-by: Athens County Public Libraries
Created attachment 186169 [details] [review] Bug 40602: Broken HTML showing in Alert 'subscriptions' tab This patch adds handling of the "no-html" flag to patron-title.inc. The OPAC alert subscriptions page passes the "no-html" flag but the include file wasn't written to include it. To test, apply the patch and log in to the OPAC as a user who has a title (salutation). - Add a serial subscription and set a notification template - Go to the OPAC and subscribe to the email notification for this subscription - Go to the patron account > Alert subscriptions tab - Verify that the last column shows an "Unsubscribe from email alerts" button. - There should be no errant HTML. Sponsored-by: Athens County Public Libraries Signed-off-by: noah <noah@inlibro.com>
Hi Noah, I notice that your sign-off line is: Signed-off-by: noah <noah@inlibro.com> For the dashboard and the release notes we can do a mail map to your full name, but you might also consider to change your git setting to have it in the patches themselves.
Created attachment 186372 [details] [review] Bug 40602: Broken HTML showing in Alert 'subscriptions' tab This patch adds handling of the "no-html" flag to patron-title.inc. The OPAC alert subscriptions page passes the "no-html" flag but the include file wasn't written to include it. To test, apply the patch and log in to the OPAC as a user who has a title (salutation). - Add a serial subscription and set a notification template - Go to the OPAC and subscribe to the email notification for this subscription - Go to the patron account > Alert subscriptions tab - Verify that the last column shows an "Unsubscribe from email alerts" button. - There should be no errant HTML. Sponsored-by: Athens County Public Libraries Signed-off-by: noah <noah@inlibro.com> Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Thanks a lot Owen!
Hi Catherine, Sorry about that — I’ve updated my Git settings so my future sign-off lines will have my full name. Thanks for pointing it out!
Created attachment 186433 [details] [review] Bug 40602: Broken HTML showing in Alert 'subscriptions' tab This patch adds handling of the "no-html" flag to patron-title.inc. The OPAC alert subscriptions page passes the "no-html" flag but the include file wasn't written to include it. To test, apply the patch and log in to the OPAC as a user who has a title (salutation). - Add a serial subscription and set a notification template - Go to the OPAC and subscribe to the email notification for this subscription - Go to the patron account > Alert subscriptions tab - Verify that the last column shows an "Unsubscribe from email alerts" button. - There should be no errant HTML. Sponsored-by: Athens County Public Libraries Signed-off-by: Noah Tremblay <noah.tremblay@inlibro.com> Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Nice work everyone! Pushed to main for 25.11
Nice work everyone! Pushed to 25.05.x
Heuuu The line : - <span class="patron-title">[% patron.title | html %]</span> Becomes : + <span class="patron-title"></span> So there is no content. I bet this is not what we want.
Yeah, this really looks weird.
Pushed into 24.11.x for 24.11.12 nice work everyone
Still not pushed, additional work needed
(In reply to Baptiste Wojtkowski (bwoj) from comment #16) > Still not pushed, additional work needed Since this is in released versions I think we should do the follow-up here: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41810
Created attachment 192938 [details] [review] Bug 40602: [25.05.x] Broken HTML showing in Alert 'subscriptions' tab This patch adds handling of the "no-html" flag to patron-title.inc. The OPAC alert subscriptions page passes the "no-html" flag but the include file wasn't written to include it. To test, apply the patch and log in to the OPAC as a user who has a title (salutation). - Add a serial subscription and set a notification template - Go to the OPAC and subscribe to the email notification for this subscription - Go to the patron account > Alert subscriptions tab - Verify that the last column shows an "Unsubscribe from email alerts" button. - There should be no errant HTML.