From 31365729dc7a373f224e762e8dbe663529543655 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Sat, 22 Nov 2008 07:20:45 +0100 Subject: [PATCH] tag_is_valid: only call iconv() when function exists --- functions.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/functions.php b/functions.php index a800a6a8..4d3e8c7b 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; -- 2.39.2