When an administrator sets up a new user (not member) using the UI I need to be able to send them an email with their login details. I have a few queries though.
The create user screen only asks for username and email address. If I handle UserService.SavedUser at this point:
1) does the user have a password and if so, how can I access it?
2) if not, I assume I can just call UserService.SavePassword conditionally within UserService.SavedUser? I am not sure how to check that the user has just been created. Any ideas?
3) I believe that at this stage, the user will not have access to any sections. How can I programatically grant access to content and media?
>> I found user.AddAllowedSection("content") which allows this.
4) Is there any mechanism for handling an administrator initiated reset password in the UI (ie resetting another user's password) - ideally, it would be nice to send an email to the user informing them of their new password.
Send Email on User Create
When an administrator sets up a new user (not member) using the UI I need to be able to send them an email with their login details. I have a few queries though.
The create user screen only asks for username and email address. If I handle UserService.SavedUser at this point:
1) does the user have a password and if so, how can I access it?
2) if not, I assume I can just call UserService.SavePassword conditionally within UserService.SavedUser? I am not sure how to check that the user has just been created. Any ideas?
3) I believe that at this stage, the user will not have access to any sections. How can I programatically grant access to content and media?
>> I found user.AddAllowedSection("content") which allows this.
4) Is there any mechanism for handling an administrator initiated reset password in the UI (ie resetting another user's password) - ideally, it would be nice to send an email to the user informing them of their new password.
is working on a reply...