how to connect callback to class method

From: Date: Tue, 24 Dec 2002 08:06:01 +0000
Subject: how to connect callback to class method
Groups: php.gtk.general 
Request: Send a blank email to php-gtk-general+get-2806@lists.php.net to get a copy of this message
Hi, if I have a class class foo{ function foo($moniker){ $butt=&new GtkButton($moniker); $butt->connect('clicked',bar); } function bar(){ echo "clicked"; } } then $butt->connect('clicked',bar); can not find the callback clicker nor can $butt->connect('clicked',$this->bar); etc I have tried other combo's of connect_object etc but have not quite got found the right way yet , thought I was getting somewhere with create_function but obviously did not :) a quick example would be much appreciated. & Happy $whatever_you_celebrate ! Regards Simon Wheeler firepages

« previous php.gtk.general (#2806) next »