UNB Components Code Reference

UnbSession::SetSessionUser method

Sets a new active session user.

public static function UnbSession::SetSessionUser ($sessionUser, $password = null, $overridePassword = false);

Parameters

sessionUser
(UnbUser) New session user. Set to null to "log out" an active user.
password  –  optional, default: null
(string) Plain login password to validate.
overridePassword  –  optional, default: false
(bool) Do not validate the provided password. This is meant to be used for setup and maintenance only! It may also be used carefully when logging in a newly created user. When currently logged in as administrator and providing no or an empty password, the new user's password is not validated either.

Exceptions thrown

BadMethodCallException If session not enabled.
InvalidArgumentException On invalid argument type or value.
UnbSecurityException On missing or rejected login password.

Member of class: UnbSession

Implementation file: session.class.php, line 410

© 2010 Yves Goergen. UNB Components Homepage. Reference generated on 2010-03-07.