On 5/12/06, Rob Church <robchur(a)gmail.com> wrote:
On 12/05/06, Dan Davis
<hokie99cpe+wiki(a)gmail.com> wrote:
Is it possible to have an email sent to an
administrative user when a
user creates a new account? Without too many edits to base MediaWiki
code?
There's an extension for this. See
http://meta.wikimedia.org/wiki/New_User_Email_Notification.
Thanks, Rob. Perfect... except for one of the features...
== 5. Notes ==
* On wikis where email address authentication is present and active(1), then
no email is sent unless the recipient's email address is validated.
(1) => MediaWiki 1.6 and later
I hacked the extension so that would be an option...
Dan
--------------------------------
# grep wgNewUserNotifUnconfirmed LocalSettings.php
$wgNewUserNotifUnconfirmed = true;
--------------------------------
--- Original.NewUserNotif.php 2006-05-12 14:49:45.254067000 +0000
+++ NewUserNotif.php 2006-05-12 14:46:07.884067000 +0000
@@ -20,6 +20,7 @@
$wgNewUserNotifSender = $wgPasswordSender;
$wgNewUserNotifTargets[] = 1;
$wgNewUserNotifEmailTargets = array();
+ $wgNewUserNotifUnconfirmed = false;
function efNewUserNotifSetup() {
global $wgHooks, $wgMessageCache;
@@ -123,11 +124,11 @@
* Send email to users
*/
function sendInternalMails() {
- global $wgNewUserNotifTargets;
+ global $wgNewUserNotifTargets,
$wgNewUserNotifUnconfirmed;
foreach( $wgNewUserNotifTargets as $userSpec ) {
if( $user =& $this->makeUser( $userSpec ) ) {
$message = $this->makeMessage(
$user->getName(), $this->user );
- if( $user->isEmailConfirmed() )
+ if( $user->isEmailConfirmed()
|| $wgNewUserNotifUnconfirmed )
$user->sendMail(
$this->makeSubject(), $message, $this->sender );
}
}