/** * Set Users Default project in preferences * @param integer $p_user_id A valid user identifier. * @param integer $p_project_id A valid project identifier. * @return void */ function user_set_default_project($p_user_id, $p_project_id) { user_pref_set_pref($p_user_id, 'default_project', (int) $p_project_id); }
/** * Sets the specified preference for the current logged in user. * * @param pref_name The name of the preference as in the preferences table. * @param pref_value The preference new value. * @access public */ function current_user_set_pref($p_pref_name, $p_pref_value) { return user_pref_set_pref(auth_get_current_user_id(), $p_pref_name, $p_pref_value); }