'UploadComplete': Upon completion of a file upload
$image: Image object representing the file that was uploaded
-'UserCan': To interrupt/advise the "user can do X to Y article" check.
+'userCan': To interrupt/advise the "user can do X to Y article" check.
If you want to display an error message, try getUserPermissionsErrors.
$title: Title object being checked against
$user : Current user object
$action: Action being checked
$result: Pointer to result returned if hook returns false. If null is returned,
- UserCan checks are continued by internal code.
+ userCan checks are continued by internal code.
'UserCreateForm': change to manipulate the login form
$template: SimpleTemplate instance for the form
$this->mUserLanguage = 'nolanguage';
}
- wfRunHooks( "InitPreferencesForm", array( $this, $request ) );
+ wfRunHooks( 'InitPreferencesForm', array( $this, $request ) );
}
function execute() {
if ( '' != $this->mNewpass && $wgAuth->allowPasswordChange() ) {
if ( $this->mNewpass != $this->mRetypePass ) {
- wfRunHooks( "PrefsPasswordAudit", array( $wgUser, $this->mNewpass, 'badretype' ) );
+ wfRunHooks( 'PrefsPasswordAudit', array( $wgUser, $this->mNewpass, 'badretype' ) );
$this->mainPrefsForm( 'error', wfMsg( 'badretype' ) );
return;
}
if (!$wgUser->checkPassword( $this->mOldpass )) {
- wfRunHooks( "PrefsPasswordAudit", array( $wgUser, $this->mNewpass, 'wrongpassword' ) );
+ wfRunHooks( 'PrefsPasswordAudit', array( $wgUser, $this->mNewpass, 'wrongpassword' ) );
$this->mainPrefsForm( 'error', wfMsg( 'wrongpassword' ) );
return;
}
try {
$wgUser->setPassword( $this->mNewpass );
- wfRunHooks( "PrefsPasswordAudit", array( $wgUser, $this->mNewpass, 'success' ) );
+ wfRunHooks( 'PrefsPasswordAudit', array( $wgUser, $this->mNewpass, 'success' ) );
$this->mNewpass = $this->mOldpass = $this->mRetypePass = '';
} catch( PasswordError $e ) {
- wfRunHooks( "PrefsPasswordAudit", array( $wgUser, $this->mNewpass, 'error' ) );
+ wfRunHooks( 'PrefsPasswordAudit', array( $wgUser, $this->mNewpass, 'error' ) );
$this->mainPrefsForm( 'error', $e->getMessage() );
return;
}
$wgUser->setEmail( $this->mUserEmail );
}
if( $oldadr != $newadr ) {
- wfRunHooks( "PrefsEmailAudit", array( $wgUser, $oldadr, $newadr ) );
+ wfRunHooks( 'PrefsEmailAudit', array( $wgUser, $oldadr, $newadr ) );
}
}
}
$msg = '';
- if ( !wfRunHooks( "SavePreferences", array( $this, $wgUser, &$msg ) ) ) {
+ if ( !wfRunHooks( 'SavePreferences', array( $this, $wgUser, &$msg ) ) ) {
print "(($msg))";
$this->mainPrefsForm( 'error', $msg );
return;
}
}
- wfRunHooks( "ResetPreferences", array( $this, $wgUser ) );
+ wfRunHooks( 'ResetPreferences', array( $this, $wgUser ) );
}
/**
}
$wgOut->addHTML( '</fieldset>' );
- wfRunHooks( "RenderPreferencesForm", array( $this, $wgOut ) );
+ wfRunHooks( 'RenderPreferencesForm', array( $this, $wgOut ) );
$token = htmlspecialchars( $wgUser->editToken() );
$skin = $wgUser->getSkin();