running a function on an eregi-substring

From: Date: Mon, 19 May 2003 10:53:37 +0000
Subject: running a function on an eregi-substring
Groups: php.general 
Request: Send a blank email to php-general+get-148147@lists.php.net to get a copy of this message
i'm having trouble using eregi_replace in a script similar to the following don't if this is possible at all but i'd like to know if this is possible, how to fix it, any help? <? $content = "hello world"; function makebold ($string) { return "<b>" . $string . "</b>"; } $output = eregi_replace("hello", makebold(\\0), $content); echo $output; ?>

« previous php.general (#148147) next »