diff -r 000000000000 -r c63de9eb7045 smarty/plugins/modifier.strip_tags.php --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/smarty/plugins/modifier.strip_tags.php Sun Mar 23 14:59:33 2008 -0400 @@ -0,0 +1,32 @@ + + * Name: strip_tags
+ * Purpose: strip html tags from text + * @link http://smarty.php.net/manual/en/language.modifier.strip.tags.php + * strip_tags (Smarty online manual) + * @author Monte Ohrt + * @param string + * @param boolean + * @return string + */ +function smarty_modifier_strip_tags($string, $replace_with_space = true) +{ + if ($replace_with_space) + return preg_replace('!<[^>]*?>!', ' ', $string); + else + return strip_tags($string); +} + +/* vim: set expandtab: */ + +?>