summaryrefslogtreecommitdiffstats
path: root/system/helpers/text_helper.php
diff options
context:
space:
mode:
authorJonatas Miguel <jonatas.df.miguel@gmail.com>2012-10-31 15:44:02 +0100
committerJonatas Miguel <jonatas.df.miguel@gmail.com>2012-10-31 15:44:02 +0100
commit3ccc386be4e0e1e4b3d47f1785e11d4b8613ef72 (patch)
treef1c8cd29775537b8da76143edeec5b6c8d659550 /system/helpers/text_helper.php
parenta9a1d2520493211ca35f7ab56866d0e154afc1c3 (diff)
parentf2b19fee7876708c7a7bb5cba6b7df682a9d2a53 (diff)
Merge branch 'develop' of git://github.com/EllisLab/CodeIgniter into develop
Diffstat (limited to 'system/helpers/text_helper.php')
-rw-r--r--system/helpers/text_helper.php11
1 files changed, 4 insertions, 7 deletions
diff --git a/system/helpers/text_helper.php b/system/helpers/text_helper.php
index 016a36c57..89602fc28 100644
--- a/system/helpers/text_helper.php
+++ b/system/helpers/text_helper.php
@@ -118,18 +118,15 @@ if ( ! function_exists('ascii_to_entities'))
/**
* High ASCII to Entities
*
- * Converts High ascii text and MS Word special characters to character entities
+ * Converts high ASCII text and MS Word special characters to character entities
*
- * @param string
+ * @param string $str
* @return string
*/
function ascii_to_entities($str)
{
- $count = 1;
- $out = '';
- $temp = array();
-
- for ($i = 0, $s = strlen($str); $i < $s; $i++)
+ $out = '';
+ for ($i = 0, $s = strlen($str), $count = 1, $temp = array(); $i < $s; $i++)
{
$ordinal = ord($str[$i]);