I am about to make a char counting function which counts input from a tinyMce textarea. Server-side validation with code like this:
$string = "is<isvery interesting <thatthis willbe stripped";
$stripped = strip_tags($string);
$count = strlen($stripped); // This will return 2
You might notice that $string has no tag at all, anyway strip_tags()
strips everything from the first less-than sign on.
Is this a bug or a feature?
This has been documented:
http://php.net/manual/en/function.strip-tags.php