From 44f669e9d81543bb16f1017c005d7739766c6d7d Mon Sep 17 00:00:00 2001 From: andi Date: Thu, 27 Jan 2005 22:14:11 +0100 Subject: utf8 safe mailfunctions added (fixes #82) darcs-hash:20050127211411-9977f-77f25921e855969dd8b7d4ded732bfdba5aec7ab.gz --- inc/utf8.php | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'inc/utf8.php') diff --git a/inc/utf8.php b/inc/utf8.php index 1d2676688..bd52a7cf2 100644 --- a/inc/utf8.php +++ b/inc/utf8.php @@ -41,6 +41,18 @@ function utf8_decodeFN($file){ return $file; } +/** + * Checks if a string contains 7bit ASCII only + * + * @author Andreas Gohr + */ +function utf8_isASCII($str){ + for($i=0; $i127) return false; + } + return true; +} + /** * Tries to detect if a string is in Unicode encoding * -- cgit v1.2.3