From 3e4c958855795ca0e7986a98b5b716c15c084463 Mon Sep 17 00:00:00 2001 From: tipaul Date: Tue, 9 Dec 2003 15:57:28 +0000 Subject: [PATCH] rolling back to working char_decode sub --- C4/Biblio.pm | 227 ++++++++++++++++++++++++++------------------------- 1 file changed, 115 insertions(+), 112 deletions(-) diff --git a/C4/Biblio.pm b/C4/Biblio.pm index dc60565530..b705088957 100644 --- a/C4/Biblio.pm +++ b/C4/Biblio.pm @@ -2192,6 +2192,9 @@ Paul POULAIN paul.poulain@free.fr # $Id$ # $Log$ +# Revision 1.78 2003/12/09 15:57:28 tipaul +# rolling back to working char_decode sub +# # Revision 1.77 2003/12/03 17:47:14 tipaul # bugfixes for biblio deletion # @@ -2987,122 +2990,122 @@ sub char_decode { $_ = $string ; # $encoding = C4::Context->preference("marcflavour") unless $encoding; if ($encoding eq "UNIMARC") { - s/\xe1/€/gm ; - s/\xe2/€/gm ; - s/\xe9/€/gm ; - s/\xec/€/gm ; - s/\xf1/€/gm ; - s/\xf3/€/gm ; - s/\xf9/€/gm ; - s/\xfb/€/gm ; - s/\xc1\x61/€/gm ; - s/\xc1\x65/€/gm ; - s/\xc1\x69/€/gm ; - s/\xc1\x6f/€/gm ; - s/\xc1\x75/€/gm ; - s/\xc1\x41/€/gm ; - s/\xc1\x45/€/gm ; - s/\xc1\x49/€/gm ; - s/\xc1\x4f/€/gm ; - s/\xc1\x55/€/gm ; - s/\xc2\x41/€/gm ; - s/\xc2\x45/€/gm ; - s/\xc2\x49/€/gm ; - s/\xc2\x4f/€/gm ; - s/\xc2\x55/€/gm ; - s/\xc2\x59/€/gm ; - s/\xc2\x61/€/gm ; - s/\xc2\x65/€/gm ; - s/\xc2\x69/€/gm ; - s/\xc2\x6f/€/gm ; - s/\xc2\x75/€/gm ; - s/\xc2\x79/€/gm ; - s/\xc3\x41/€/gm ; - s/\xc3\x45/€/gm ; - s/\xc3\x49/€/gm ; - s/\xc3\x4f/€/gm ; - s/\xc3\x55/€/gm ; - s/\xc3\x61/€/gm ; - s/\xc3\x65/€/gm ; - s/\xc3\x69/€/gm ; - s/\xc3\x6f/€/gm ; - s/\xc3\x75/€/gm ; - s/\xc4\x41/€/gm ; - s/\xc4\x4e/€/gm ; - s/\xc4\x4f/€/gm ; - s/\xc4\x61/€/gm ; - s/\xc4\x6e/€/gm ; - s/\xc4\x6f/€/gm ; - s/\xc8\x45/€/gm ; - s/\xc8\x49/€/gm ; - s/\xc8\x65/€/gm ; - s/\xc8\x69/€/gm ; - s/\xc8\x76/€/gm ; - s/\xc9\x41/€/gm ; - s/\xc9\x4f/€/gm ; - s/\xc9\x55/€/gm ; - s/\xc9\x61/€/gm ; - s/\xc9\x6f/€/gm ; - s/\xc9\x75/€/gm ; - s/\xca\x41/€/gm ; - s/\xca\x61/€/gm ; - s/\xd0\x43/€/gm ; - s/\xd0\x63/€/gm ; + s/\xe1/Æ/gm ; + s/\xe2/Ð/gm ; + s/\xe9/Ø/gm ; + s/\xec/þ/gm ; + s/\xf1/æ/gm ; + s/\xf3/ð/gm ; + s/\xf9/ø/gm ; + s/\xfb/ß/gm ; + s/\xc1\x61/à/gm ; + s/\xc1\x65/è/gm ; + s/\xc1\x69/ì/gm ; + s/\xc1\x6f/ò/gm ; + s/\xc1\x75/ù/gm ; + s/\xc1\x41/À/gm ; + s/\xc1\x45/È/gm ; + s/\xc1\x49/Ì/gm ; + s/\xc1\x4f/Ò/gm ; + s/\xc1\x55/Ù/gm ; + s/\xc2\x41/Á/gm ; + s/\xc2\x45/É/gm ; + s/\xc2\x49/Í/gm ; + s/\xc2\x4f/Ó/gm ; + s/\xc2\x55/Ú/gm ; + s/\xc2\x59/Ý/gm ; + s/\xc2\x61/á/gm ; + s/\xc2\x65/é/gm ; + s/\xc2\x69/í/gm ; + s/\xc2\x6f/ó/gm ; + s/\xc2\x75/ú/gm ; + s/\xc2\x79/ý/gm ; + s/\xc3\x41/Â/gm ; + s/\xc3\x45/Ê/gm ; + s/\xc3\x49/Î/gm ; + s/\xc3\x4f/Ô/gm ; + s/\xc3\x55/Û/gm ; + s/\xc3\x61/â/gm ; + s/\xc3\x65/ê/gm ; + s/\xc3\x69/î/gm ; + s/\xc3\x6f/ô/gm ; + s/\xc3\x75/û/gm ; + s/\xc4\x41/Ã/gm ; + s/\xc4\x4e/Ñ/gm ; + s/\xc4\x4f/Õ/gm ; + s/\xc4\x61/ã/gm ; + s/\xc4\x6e/ñ/gm ; + s/\xc4\x6f/õ/gm ; + s/\xc8\x45/Ë/gm ; + s/\xc8\x49/Ï/gm ; + s/\xc8\x65/ë/gm ; + s/\xc8\x69/ï/gm ; + s/\xc8\x76/ÿ/gm ; + s/\xc9\x41/Ä/gm ; + s/\xc9\x4f/Ö/gm ; + s/\xc9\x55/Ü/gm ; + s/\xc9\x61/ä/gm ; + s/\xc9\x6f/ö/gm ; + s/\xc9\x75/ü/gm ; + s/\xca\x41/Å/gm ; + s/\xca\x61/å/gm ; + s/\xd0\x43/Ç/gm ; + s/\xd0\x63/ç/gm ; # this handles non-sorting blocks (if implementation requires this) $string = nsb_clean($_) ; } elsif ($encoding eq "USMARC" || $encoding eq "MARC21") { if(/[\xc1-\xff]/) { - s/\xe1\x61/€/gm ; - s/\xe1\x65/€/gm ; - s/\xe1\x69/€/gm ; - s/\xe1\x6f/€/gm ; - s/\xe1\x75/€/gm ; - s/\xe1\x41/€/gm ; - s/\xe1\x45/€/gm ; - s/\xe1\x49/€/gm ; - s/\xe1\x4f/€/gm ; - s/\xe1\x55/€/gm ; - s/\xe2\x41/€/gm ; - s/\xe2\x45/€/gm ; - s/\xe2\x49/€/gm ; - s/\xe2\x4f/€/gm ; - s/\xe2\x55/€/gm ; - s/\xe2\x59/€/gm ; - s/\xe2\x61/€/gm ; - s/\xe2\x65/€/gm ; - s/\xe2\x69/€/gm ; - s/\xe2\x6f/€/gm ; - s/\xe2\x75/€/gm ; - s/\xe2\x79/€/gm ; - s/\xe3\x41/€/gm ; - s/\xe3\x45/€/gm ; - s/\xe3\x49/€/gm ; - s/\xe3\x4f/€/gm ; - s/\xe3\x55/€/gm ; - s/\xe3\x61/€/gm ; - s/\xe3\x65/€/gm ; - s/\xe3\x69/€/gm ; - s/\xe3\x6f/€/gm ; - s/\xe3\x75/€/gm ; - s/\xe4\x41/€/gm ; - s/\xe4\x4e/€/gm ; - s/\xe4\x4f/€/gm ; - s/\xe4\x61/€/gm ; - s/\xe4\x6e/€/gm ; - s/\xe4\x6f/€/gm ; - s/\xe8\x45/€/gm ; - s/\xe8\x49/€/gm ; - s/\xe8\x65/€/gm ; - s/\xe8\x69/€/gm ; - s/\xe8\x76/€/gm ; - s/\xe9\x41/€/gm ; - s/\xe9\x4f/€/gm ; - s/\xe9\x55/€/gm ; - s/\xe9\x61/€/gm ; - s/\xe9\x6f/€/gm ; - s/\xe9\x75/€/gm ; - s/\xea\x41/€/gm ; - s/\xea\x61/€/gm ; + s/\xe1\x61/à/gm ; + s/\xe1\x65/è/gm ; + s/\xe1\x69/ì/gm ; + s/\xe1\x6f/ò/gm ; + s/\xe1\x75/ù/gm ; + s/\xe1\x41/À/gm ; + s/\xe1\x45/È/gm ; + s/\xe1\x49/Ì/gm ; + s/\xe1\x4f/Ò/gm ; + s/\xe1\x55/Ù/gm ; + s/\xe2\x41/Á/gm ; + s/\xe2\x45/É/gm ; + s/\xe2\x49/Í/gm ; + s/\xe2\x4f/Ó/gm ; + s/\xe2\x55/Ú/gm ; + s/\xe2\x59/Ý/gm ; + s/\xe2\x61/á/gm ; + s/\xe2\x65/é/gm ; + s/\xe2\x69/í/gm ; + s/\xe2\x6f/ó/gm ; + s/\xe2\x75/ú/gm ; + s/\xe2\x79/ý/gm ; + s/\xe3\x41/Â/gm ; + s/\xe3\x45/Ê/gm ; + s/\xe3\x49/Î/gm ; + s/\xe3\x4f/Ô/gm ; + s/\xe3\x55/Û/gm ; + s/\xe3\x61/â/gm ; + s/\xe3\x65/ê/gm ; + s/\xe3\x69/î/gm ; + s/\xe3\x6f/ô/gm ; + s/\xe3\x75/û/gm ; + s/\xe4\x41/Ã/gm ; + s/\xe4\x4e/Ñ/gm ; + s/\xe4\x4f/Õ/gm ; + s/\xe4\x61/ã/gm ; + s/\xe4\x6e/ñ/gm ; + s/\xe4\x6f/õ/gm ; + s/\xe8\x45/Ë/gm ; + s/\xe8\x49/Ï/gm ; + s/\xe8\x65/ë/gm ; + s/\xe8\x69/ï/gm ; + s/\xe8\x76/ÿ/gm ; + s/\xe9\x41/Ä/gm ; + s/\xe9\x4f/Ö/gm ; + s/\xe9\x55/Ü/gm ; + s/\xe9\x61/ä/gm ; + s/\xe9\x6f/ö/gm ; + s/\xe9\x75/ü/gm ; + s/\xea\x41/Å/gm ; + s/\xea\x61/å/gm ; # this handles non-sorting blocks (if implementation requires this) $string = nsb_clean($_) ; } -- 2.39.5