LP#1624846 Add charset declaration to TPAC print output
authorDan Scott <dscott@laurentian.ca>
Sun, 18 Sep 2016 13:16:27 +0000 (09:16 -0400)
committerMike Rylander <mrylander@gmail.com>
Tue, 20 Sep 2016 15:03:44 +0000 (11:03 -0400)
Non-ASCII characters were printed incorrectly in some browsers, such as
Firefox, that still default to ISO-8859-1 encodings in the absence of a
specifically declared encoding.

Our output encoding will always be UTF-8, so declare it.

Signed-off-by: Dan Scott <dscott@laurentian.ca>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
Open-ILS/src/templates/opac/myopac/receipt_print.tt2
Open-ILS/src/templates/opac/record/print.tt2

index fe68495..64237e2 100644 (file)
@@ -1,6 +1,7 @@
 [%# sic! no wrapper %]
 <html>
     <head>
 [%# sic! no wrapper %]
 <html>
     <head>
+        <meta charset="utf-8">
         <title>[% l('Receipt') %]</title>
     </head>
     <body onload="if (document.getElementById('printable-receipt')) window.print();">
         <title>[% l('Receipt') %]</title>
     </head>
     <body onload="if (document.getElementById('printable-receipt')) window.print();">
index d5d94e6..24cb94e 100644 (file)
@@ -1,6 +1,7 @@
 [% PROCESS 'opac/parts/header.tt2' %]
 <html>
     <head>
 [% PROCESS 'opac/parts/header.tt2' %]
 <html>
     <head>
+        <meta charset="utf-8">
         <title>[% l('Print Record') %]</title>
         <style type="text/css" media="print">.noprint {display: none}</style>
     </head>
         <title>[% l('Print Record') %]</title>
         <style type="text/css" media="print">.noprint {display: none}</style>
     </head>