- Posts: 83
- Thank you received: 7
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
Informations on createNewUser plugin event
Less
More
2 years 4 months ago #211608
by tassoman
«All your survey answers are belong to us »
Informations on createNewUser plugin event was created by tassoman
Anyone who knows how to
plugin
the
event createNewUser
? I'd like to fire an email to named email address (plugin settings) whenever a new user admin gets created, by webserver authentication.
Sadly, the wiki is undocumented about it. Also in the code , I can't find something useful.
Any help is appreciated, thanks in advance.
Sadly, the wiki is undocumented about it. Also in the code , I can't find something useful.
Any help is appreciated, thanks in advance.
«All your survey answers are belong to us »
The topic has been locked.
- DenisChenu
-
- Offline
- LimeSurvey Community Team
-
Less
More
- Posts: 13146
- Thank you received: 2423
2 years 4 months ago #211613
by DenisChenu
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Replied by DenisChenu on topic Informations on createNewUser plugin event
Seems an event when user is created by admin only
github.com/LimeSurvey/LimeSurvey/blob/ec...action.php#L118-L122
Done before creation …
You muts use POST value … to get the email etc … Yii::app()->request->getPost('new_user')
github.com/LimeSurvey/LimeSurvey/blob/ec...action.php#L118-L122
Done before creation …
You muts use POST value … to get the email etc … Yii::app()->request->getPost('new_user')
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
Less
More
- Posts: 83
- Thank you received: 7
2 years 3 months ago #211757
by tassoman
«All your survey answers are belong to us »
Replied by tassoman on topic Informations on createNewUser plugin event
Maybe should I use hook to afterModelSave event by userModel ?
manual.limesurvey.org/AfterModelSave
Looking for isNewRecord property?
www.yiiframework.com/doc/api/1.1/CActive...d#isNewRecord-detail
manual.limesurvey.org/AfterModelSave
Looking for isNewRecord property?
www.yiiframework.com/doc/api/1.1/CActive...d#isNewRecord-detail
«All your survey answers are belong to us »
The topic has been locked.
- DenisChenu
-
- Offline
- LimeSurvey Community Team
-
Less
More
- Posts: 13146
- Thank you received: 2423
2 years 3 months ago #211765
by DenisChenu
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Replied by DenisChenu on topic Informations on createNewUser plugin event
I don't use a lot AfterModelSave (here AfterUserSave)
But yes : i think you can use
$oUser = $this->getEvent()->get('model');
if($oUser->isNewRecord …
Another way (in 4.4) : github.com/LimeSurvey/LimeSurvey/blob/ec.../useraction.php#L165
manual.limesurvey.org/BeforeEmail
But yes : i think you can use
$oUser = $this->getEvent()->get('model');
if($oUser->isNewRecord …
Another way (in 4.4) : github.com/LimeSurvey/LimeSurvey/blob/ec.../useraction.php#L165
manual.limesurvey.org/BeforeEmail
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.