diff options
-rw-r--r-- | docs/users.md | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/docs/users.md b/docs/users.md index a1d98a3..ad83338 100644 --- a/docs/users.md +++ b/docs/users.md @@ -68,6 +68,26 @@ Gatekeeper::register($credentials); **NOTE:** The permissions by the name/id you use must exist *before* the user, otherwise the link is not created. +You can also create groups the same way: + +```php +<?php +$credentials = array( + 'username' => 'ccornutt', + 'password' => 'test1', + 'email' => 'ccornutt@phpdeveloper.org', + 'first_name' => 'Chris', + 'last_name' => 'Cornutt' +); +// Use can use permission names +$credentials['groups'] = array('group1', 'group2'); +// or use IDs +$credentials['groups'] = array(1, 2); + +Gatekeeper::register($credentials); +?> +``` + ## Removing users Deleteing user records can be done with the `deleteUserById` method: |