tsgeoff Posted February 14, 2013 Share Posted February 14, 2013 Hey all. Is there a specified restriction on the kinds of functions that can be passed into the add_hook() function? For example, I have a few hooks that I've grouped together on a single object. However, it seems as if WHMCS is not able to add hooks from object methods or static class methods. I've tried adding hooks like this: $hookObj = new SomeHookObject(); add_hook('HookName', 1, $hookObj->hookName()); And like this: add_hook('HookName', 1, 'SomeHookObject::hookName'); But neither way has it working. Plain old functions work. I can only assume that WHMCS enforces functions only in some way? Any help would be appreciated. 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.