Added partial support for iso-8859-15 to rfc1522Decode.
authorgustavf <gustavf@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Thu, 24 Feb 2000 09:44:36 +0000 (09:44 +0000)
committergustavf <gustavf@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Thu, 24 Feb 2000 09:44:36 +0000 (09:44 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@243 7612ce4b-ef26-0410-bec9-ea0150e637f0

functions/mime.php

index aec1669..f891a3c 100644 (file)
             $replace = quoted_printable_decode($replace);
          }
 
-         // Only US-ASCII and ISO-8859-1 can be displayed without further ado
-         if ($res[2] != "" && $res[2] != "1") {
+         if ($res[2] != "" && $res[2] == "15") {
+            // Remove all chararacters in iso-8859-15 that is not the same
+            // as in iso-8859-1
+            $replace = strtr($replace, "\244\246\250\255\264\270\274\275".
+                             "\276", "??????????");
+         } else if ($res[2] != "" && $res[2] != "1") {
             // This gets rid of all characters with over 0x9F for other
-            // charsets.
+            // iso-8859 charsets.
             $replace = strtr($replace, "\240\241\242\243\244\245\246\247".
                              "\250\251\252\253\254\255\256\257".
                              "\260\261\262\263\264\265\266\267".