[wp-hackers] register_activation_hook() problem

Mike Little mike at zed1.com
Tue Jul 28 16:18:36 UTC 2009

2009/7/28 Adam Taylor <adamjctaylor at gmail.com>:

> I'm pretty sure I haven't defined the function more than once.. the whole
> code is here:
> http://pastebin.com/m1feb2d16
> If that helps anyone help me..

You can create your install function on the fly like this:

register_activation_hook(__FILE__, create_function('', 'global
$thumbs; $thumbs = new ThumbsUp; $thumbs->installThumbsUp();'));

(all on one line)

Mike Little

More information about the wp-hackers mailing list