First, the example you give will replace "is" with "," if "is" is the ONLY work in the line. You indicate this with the ^$ construct.
Are you trying to replace only the first occurrence if "is"? -----Original Message----- From: Desikan [mailto:[EMAIL PROTECTED]] Sent: Friday, February 08, 2002 6:42 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] Exact String replace with eregi_replace() hi I'm trying to replace the exact match of 'is' with ','.. But all the matches of 'is' in the string gets replaced.... how can i avoid this??? <?php echo ereg_replace ("^is$", ",", "This is a dismissal of windows based technology"); ?> rgds, Desikan -- Desikan [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php