I am trying to use an instance method as a callback for PHP 5.2.1. I am aware that as of PHP 5.4 you can use \[code\]$this\[/code\] inside a closure, and in PHP 5.3 you can rename \[code\]$this\[/code\] to \[code\]$self\[/code\] and pass that to the closure. However, neither of these methods will suffice since I need this to work for PHP 5.2.1. The two commented lines was my last attempt. That results in \[code\]Fatal error: Call to a member function hello() on a non-object\[/code\] - is there anyway I can have a callback to an instance method in PHP 5.2.1?\[code\]<?phpclass Test { public function __construct() { $self = &$this; $cb = function() use ( $self ) { $self->hello(); }; call_user_func( $cb ); // $cb = create_function( '$self', '$self->hello();' ); // call_user_func( $cb ); } public function hello() { echo "Hello, World!\n"; }}$t = new Test();\[/code\]