Using XenForo_Model_User functions in static function?

SirWill

Member
hey,

I have an cron job which requires a static method but I would like to use the XenForo_Model_User functions there to get the user by id.

Is there any way to do that or would I need to create my own query to get the user?
 
Shouldn't be a problem. You can instantiate the user model like this:
PHP:
$userModel = XenForo_Model::create('XenForo_Model_User');
 
Back
Top Bottom