MediaWiki REL1_40
|
Command for sending emails to users. More...
Static Public Member Functions | |
static | getPermissionsError ( $user, $editToken, Config $config=null) |
Check whether a user is allowed to send email. | |
static | getTarget ( $target, User $sender) |
Validate target User. | |
static | submit (array $data, IContextSource $context) |
Really send a mail. | |
static | validateTarget ( $target, User $sender) |
Validate target User. | |
Command for sending emails to users.
Definition at line 43 of file EmailUser.php.
|
static |
Check whether a user is allowed to send email.
Definition at line 131 of file EmailUser.php.
References MediaWiki\MainConfigNames\EnableEmail, MediaWiki\MainConfigNames\EnableUserEmail, MediaWiki\MediaWikiServices\getInstance(), and wfDebug().
|
static |
Validate target User.
Definition at line 51 of file EmailUser.php.
References User\newFromName(), MediaWiki\Mail\EmailUser\validateTarget(), and wfDebug().
Referenced by MediaWiki\Mail\EmailUser\submit().
|
static |
Really send a mail.
Permissions should have been checked using getPermissionsError(). It is probably also a good idea to check the edit token and ping limiter in advance.
array | $data | |
IContextSource | $context |
MWException | if EmailUser hook sets the error to something unsupported |
Definition at line 186 of file EmailUser.php.
References $type, MediaWiki\MainConfigNames\EnableSpecialMute, IContextSource\getConfig(), MediaWiki\MediaWikiServices\getInstance(), MediaWiki\Mail\EmailUser\getTarget(), SpecialPage\getTitleFor(), IContextSource\getUser(), MessageLocalizer\msg(), MediaWiki\MainConfigNames\PasswordSender, and MediaWiki\MainConfigNames\UserEmailUseReplyTo.
|
static |
Validate target User.
Definition at line 71 of file EmailUser.php.
References User\getId(), MediaWiki\MediaWikiServices\getInstance(), User\isNewbie(), MediaWiki\Preferences\MultiUsernameFilter\splitIds(), and wfDebug().
Referenced by MediaWiki\Mail\EmailUser\getTarget().