Sfoglia il codice sorgente

[ZF-10159] Zend_Locale_Format:

- added a detection for PRCE without UTF-8 support

git-svn-id: http://framework.zend.com/svn/framework/standard/trunk@22808 44c647ce-9c0f-0410-b52a-842ac1e357ba
thomas 15 anni fa
parent
commit
be9158fe67
1 ha cambiato i file con 3 aggiunte e 3 eliminazioni
  1. 3 3
      library/Zend/Locale/Format.php

+ 3 - 3
library/Zend/Locale/Format.php

@@ -194,7 +194,7 @@ class Zend_Locale_Format
     public static function convertNumerals($input, $from, $to = null)
     {
         if (!self::_getUniCodeSupport()) {
-            throw new Zend_Locale_Exception('Sorry, your PCRE extension does not support UTF8 which is needed for the I18N core');
+            trigger_error("Sorry, your PCRE extension does not support UTF8 which is needed for the I18N core", E_USER_NOTICE);
         }
 
         $from   = strtolower($from);
@@ -502,7 +502,7 @@ class Zend_Locale_Format
     public static function isNumber($input, array $options = array())
     {
         if (!self::_getUniCodeSupport()) {
-            throw new Zend_Locale_Exception('Sorry, your PCRE extension does not support UTF8 which is needed for the I18N core');
+            trigger_error("Sorry, your PCRE extension does not support UTF8 which is needed for the I18N core", E_USER_NOTICE);
         }
 
         $options = self::_checkOptions($options) + self::$_options;
@@ -766,7 +766,7 @@ class Zend_Locale_Format
     private static function _parseDate($date, $options)
     {
         if (!self::_getUniCodeSupport()) {
-            throw new Zend_Locale_Exception('Sorry, your PCRE extension does not support UTF8 which is needed for the I18N core');
+            trigger_error("Sorry, your PCRE extension does not support UTF8 which is needed for the I18N core", E_USER_NOTICE);
         }
 
         $options = self::_checkOptions($options) + self::$_options;