$what,'value'=>$value); } return $result; } static function saveSettings($what, $value) { if ($what != null) { $insertString = "INSERT INTO srv_user_setting_for_survey (sid, uid, what, value) VALUES " . "('".self::$surveyId."', '".self::$userId."', '".$what."', '".$value."') " . "ON DUPLICATE KEY UPDATE value='".$value."'"; $insert = sisplet_query($insertString); sisplet_query('COMMIT'); } return $insert; } static function removeSettings($what) { if ($what != null) { $deleteString = "DELETE FROM srv_user_setting_for_survey WHERE sid = '".self::$surveyId."' AND uid = '".self::$userId."' AND what = '".$what."'"; $delete = sisplet_query($deleteString); } return $delete; } static function getUserRow () { global $global_user_id; if (!self::$rowUserInit) { $queryUserInit = sisplet_query("SELECT * FROM users WHERE id = '".$global_user_id."'"); self::$rowUserInit = mysqli_fetch_assoc($queryUserInit); } return self::$rowUserInit; } } ?>