Skip to content
Permalink
Browse files

Fixed grammar, wrong method and updated places using Multibyte

  • Loading branch information...
jrbasso committed Sep 20, 2012
1 parent 0604c98 commit e6106bd1f7f6497c26d3718f9932025be3c000a3
@@ -61,7 +61,7 @@ endif;
echo '</span>';
else:
echo '<span class="notice">';
echo __d('cake_dev', 'Your version of PHP do NOT have mbstring extension loaded.');
echo __d('cake_dev', 'Your version of PHP does NOT have the mbstring extension loaded.');
echo '</span>';
endif;
?>
@@ -63,7 +63,7 @@ endif;
echo '</span>';
else:
echo '<span class="notice">';
echo __d('cake_dev', 'Your version of PHP do NOT have mbstring extension loaded.');
echo __d('cake_dev', 'Your version of PHP does NOT have the mbstring extension loaded.');
echo '</span>';
endif;
?>
@@ -21,9 +21,9 @@
use Cake\Core\App;
use Cake\Core\Configure;
use Cake\Core\Plugin;
use Cake\I18n\Multibyte;
use Cake\Utility\Hash;
use Cake\Utility\Inflector;
use Cake\Utility\String;
mb_internal_encoding(Configure::read('App.encoding'));
@@ -603,7 +603,7 @@ protected function _parseLiteralValue($string) {
return implode('', array_map('chr', array_map('hexdec', array_filter(explode($delimiter, $string)))));
}
if (preg_match('/U([0-9a-fA-F]{4})/', $string, $match)) {
return Multibyte::ascii(array(hexdec($match[1])));
return String::ascii(array(hexdec($match[1])));
}
return $string;
}
@@ -146,7 +146,7 @@ public static function strrchr($haystack, $needle, $part = false) {
* @see mb_strrichr function
*/
public static function strrichr($haystack, $needle, $part = false) {
return mb_strrichr;
return mb_strrichr($haystack, $needle, $part);
}
/**
@@ -13,8 +13,8 @@
* @license MIT License (http://www.opensource.org/licenses/mit-license.php)
*/
namespace Cake\View\Helper;
use Cake\I18n\Multibyte;
use Cake\View\Helper;
use Cake\Utility\String;
/**
* JsEngineBaseClass
@@ -229,7 +229,7 @@ protected function _utf8ToHex($string) {
break;
}
$charbits = $string{$i} . $string{$i + 1};
$char = Multibyte::utf8($charbits);
$char = String::utf8($charbits);
$return .= sprintf('\u%04s', dechex($char[0]));
$i += 1;
break;
@@ -240,7 +240,7 @@ protected function _utf8ToHex($string) {
break;
}
$charbits = $string{$i} . $string{$i + 1} . $string{$i + 2};
$char = Multibyte::utf8($charbits);
$char = String::utf8($charbits);
$return .= sprintf('\u%04s', dechex($char[0]));
$i += 2;
break;
@@ -251,7 +251,7 @@ protected function _utf8ToHex($string) {
break;
}
$charbits = $string{$i} . $string{$i + 1} . $string{$i + 2} . $string{$i + 3};
$char = Multibyte::utf8($charbits);
$char = String::utf8($charbits);
$return .= sprintf('\u%04s', dechex($char[0]));
$i += 3;
break;
@@ -262,7 +262,7 @@ protected function _utf8ToHex($string) {
break;
}
$charbits = $string{$i} . $string{$i + 1} . $string{$i + 2} . $string{$i + 3} . $string{$i + 4};
$char = Multibyte::utf8($charbits);
$char = String::utf8($charbits);
$return .= sprintf('\u%04s', dechex($char[0]));
$i += 4;
break;
@@ -273,7 +273,7 @@ protected function _utf8ToHex($string) {
break;
}
$charbits = $string{$i} . $string{$i + 1} . $string{$i + 2} . $string{$i + 3} . $string{$i + 4} . $string{$i + 5};
$char = Multibyte::utf8($charbits);
$char = String::utf8($charbits);
$return .= sprintf('\u%04s', dechex($char[0]));
$i += 5;
break;

0 comments on commit e6106bd

Please sign in to comment.
You can’t perform that action at this time.