method set documentation in bbn\User\Preferences
Sets the preference config for the current user by the preference's ID and returns the number of rows change.
Example
$pref->set('042b29722c2f11eca47652540000cfbe', []);
// (int) = 1;
function(string $id, array $cfg = NULL)
{
return $this->db->update(
$this->class_cfg['table'],
[
$this->fields['cfg'] => $cfg ? json_encode($this->getCfg(false, $cfg)) : null
],
[
$this->fields['id'] => $id
]
);
}
Sets the preference config for the current user by the preference's ID and returns the number of rows change. BBN is a suite of PHP and JS libraries and VueJS components - all open-source! bbn.io, build applications, the quick way
This website uses cookies to ensure you get the best experience on our website.
© 2011-2025
BBN Solutions