views:

18

answers:

1

I have used the preg_replace_callback as

$string = preg_replace_callback($pattern,'CreateTemplatesController::callbackhandler',$string );

I have called the callbackhandler function with the class name as this function is a private static function.

Problem is "callbackhandler" function is not getting called.

Please post if any one know the reason for the same. Thanks in Advance

A: 

According to http://www.php.net/manual/en/language.pseudo-types.php#language.types.callback

It should be array('CreateTemplatesController', 'callbackhandler')

cthom06