note 89410 modified in function.strip-tags by danbrown

From: Date: Fri, 06 Mar 2009 16:48:42 +0000
Subject: note 89410 modified in function.strip-tags by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-151561@lists.php.net to get a copy of this message
a function that decides if < is a start of a tag or a lower than / lower than + equal: <?php function lt_replace($str){ return preg_replace("/<([^[:alpha:]])/", '&lt;\\1', $str); } ?> It's to be used before strip_slashes. --was-- a function that decides if < is a start of a tag or a lower than / lower than + equal: function lt_replace($str){ return preg_replace("/<([^[:alpha:]])/", '&lt;\\1', $str); } It's to be used before strip_slashes. http://php.net/manual/en/function.strip-tags.php

« previous php.notes (#151561) next »