PHP midgard_user
This part of API is forward compatible and it's recommended for Midgard 1.9/2.0. This is experimental section.
MidgardUser ( midgard_user ) class is a proxy between person records ( represented by built in midgard_person class ) and user's account. It also let's you authenticate using user's account and login in to Midgard sitegroup.
It also provides very basic and low level access control system.
Minimum version: 1.9
Creating new midgard_user ( Constructor )
midgard_user object is instantiated with midgard_person object as argument. Person object must be an object which is already fetched from database.
$person = new midgard_person($guid);
$user = new midgard_user($person);
auth method is recommended if you need to authenticate and get new user object.
Midgard User methods
- auth
- is_user
- is_admin
- is_root
- set_active
- password
- get_person
