diff options
| author | Andrew Dolgov <fox@madoka.spb.ru> | 2008-11-22 07:20:45 +0100 |
|---|---|---|
| committer | Andrew Dolgov <fox@madoka.spb.ru> | 2008-11-22 07:20:45 +0100 |
| commit | 31365729dc7a373f224e762e8dbe663529543655 (patch) | |
| tree | 814d13509cc856ca14a4a7f0c13f3033aeca2d3b | |
| parent | 19a1da0d7a4d7f1d95ce3631a378e0278eb56af8 (diff) | |
tag_is_valid: only call iconv() when function exists
| -rw-r--r-- | functions.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/functions.php b/functions.php index a800a6a83..4d3e8c7b6 100644 --- a/functions.php +++ b/functions.php @@ -4503,7 +4503,10 @@ if ($tag == '') return false; if (preg_match("/^[0-9]*$/", $tag)) return false; - $tag = iconv("utf-8", "utf-8", $tag); + if (function_exists('iconv')) { + $tag = iconv("utf-8", "utf-8", $tag); + } + if (!$tag) return false; return true; |