Marcel
Active member
Could someone point me in the right direction please?
I've tried a multitude of ways and I just can't get my head round it
I have an addon that creates a customfield, lets call it mycustomfield (A 3 digit integer).
I have the value to be inserted stored in $myinteger
I would have assumed it would be something along the lines of (For demonstration purposes)
$userId = '1';
$userModel = XenForo_Model::create('XenForo_Model_User');
$userProfile = $userModel->getFullUserById($userId);
$customFields = unserialize($userProfile['custom_fields']);
$dwUser = XenForo_DataWriter::create('XenForo_DataWriter_User');
errrr??
$dwUser>save();
return;
Please note (if this makes a difference), this will be part of a cron job that will daily calculate the three digit integer based on posts over particular forums. That part of the code isn't ready yet.....I want to get this part done first.
I've read Furhman's guide to using the datawriter, and Chris D's various guides, but I'm stuck at the moment.
Thanks
I've tried a multitude of ways and I just can't get my head round it
I have an addon that creates a customfield, lets call it mycustomfield (A 3 digit integer).
I have the value to be inserted stored in $myinteger
I would have assumed it would be something along the lines of (For demonstration purposes)
$userId = '1';
$userModel = XenForo_Model::create('XenForo_Model_User');
$userProfile = $userModel->getFullUserById($userId);
$customFields = unserialize($userProfile['custom_fields']);
$dwUser = XenForo_DataWriter::create('XenForo_DataWriter_User');
errrr??
$dwUser>save();
return;
Please note (if this makes a difference), this will be part of a cron job that will daily calculate the three digit integer based on posts over particular forums. That part of the code isn't ready yet.....I want to get this part done first.
I've read Furhman's guide to using the datawriter, and Chris D's various guides, but I'm stuck at the moment.
Thanks