note 54128 deleted from function.eregi by betz

From: Date: Sun, 10 Jul 2005 11:54:57 +0000
Subject: note 54128 deleted from function.eregi by betz
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-91733@lists.php.net to get a copy of this message
Note Submitter: Zach at fsw dot cn ---- To liam at sunwise dot co dot uk (note below) eregi is a great tool tool for comparisons, to check to see if a string contains another string, etc What you are trying to do can be done much better with many other commands like htmlentitities which will just convert all problem causing characters to their printable equal. Or even more simple - $string=str_replace('<','< ',$string); - which is gonna break everything that someone might try Or look in strip_tags - it in itself can be defeated, but there is many user notes that are probably much closer to what you are trying to do.

« previous php.notes (#91733) next »