[wp-hackers] Class function in Hook

John Kolbert list at johnkolbert.com
Sat Aug 15 23:23:55 UTC 2009


This question may just show a lack of PHP knowledge, but I was  
wondering what the difference between these two were:

// First
	$bf_vendor = new bf_vendor();

	register_activation_hook(__FILE__, array(&$bf_vendor, 'installTable'));

// Second

	register_activation_hook(__FILE__, array('bf_vendor', 'installTable'));


Both of these methods seemed to work. I was just wondering if there is  
any difference or preferred method between the two. Thanks guys.

-John

John Kolbert
http://www.johnkolbert.com/





More information about the wp-hackers mailing list