on &action=edit.
$EditPage: the EditPage object
+'AlternateUserMailer': Called before mail is sent so that mail could
+be logged (or something else) instead of using PEAR or SMTP
+$UserMailer: the EditPage object
+$headers: Associative array of headers for the email
+$to: MailAddress object or array
+$from: From address
+$subject: Subject of the email
+$body: Body of the message
+
'APIAfterExecute': after calling the execute() method of an API module.
Use this to extend core API modules.
&$module: Module object
$headers['X-Mailer'] = 'MediaWiki mailer';
$headers['From'] = $from->toString();
+ $ret = wfRunHooks( 'AlternateUserMailer', array( $this, $headers, $to, $from, $subject, $body, $replyto, $contentType ) ) ) {
+ if ( $ret === false ) {
+ return Status::newGood();
+ } else if ( $ret != true ) {
+ return Status::newFatal( 'php-mail-error', $ret );
+ }
+
if ( is_array( $wgSMTP ) ) {
if ( function_exists( 'stream_resolve_include_path' ) ) {
$found = stream_resolve_include_path( 'Mail.php' );