diff options
author | Urban Müller | 2012-04-11 07:55:00 +0000 |
---|---|---|
committer | Urban Müller | 2012-04-11 07:55:00 +0000 |
commit | af6eae0ff1f2dcca16f86493b5052a3544c0a6f7 (patch) | |
tree | 08ec16aa05837e76e3dfdd666c85afa902bc7cb9 | |
parent | e47355b6253b90b3eab17aeb6a76147433cac15d (diff) | |
download | itools-af6eae0ff1f2dcca16f86493b5052a3544c0a6f7.tar.gz itools-af6eae0ff1f2dcca16f86493b5052a3544c0a6f7.tar.bz2 itools-af6eae0ff1f2dcca16f86493b5052a3544c0a6f7.zip |
more verbose errmsg
-rw-r--r-- | it.class | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -384,7 +384,7 @@ static function replace($replacements, $string, $p = array()) $result = preg_replace($patterns, $replacements, $string, isset($p['limit']) ? $p['limit'] : -1); if ($result === null && preg_last_error() == PREG_BAD_UTF8_ERROR) - it::error("Input to it::replace is not valid utf-8"); + it::error("Invalid utf-8 in it::replace haystack: " . substr($string, 0, 500)); # UTF8SAFE return $result; } |