Extension:UserLoginLog

From MediaWiki.org

Jump to: navigation, search
Manual on MediaWiki Extensions
List of MediaWiki Extensions
UserLoginLog

Release status: beta

Implementation User activity
Description Creates a new MediaWiki log for user logins and logout events
Author(s) User:Nad
Version 1.0.0 (2007-07-30)
MediaWiki All versions (only tested on 1.10) - doesn't work on 1.71 as is, see discussion for patch
Download OrganicDesign:Extension:UserLoginLog.php
Hooks used UserLoginForm

UserLoginComplete
UserLogout
UserLogoutComplete

The new log appears in the list on the Special:Logs page.

[edit] Installation

Create a directory called UserLoginLog in your wiki's extensions directory. Then, copy the source code from OrganicDesign:Extension:UserLoginLog.php and save it as a file called UserLoginLog.php into the newly created directory.

Add an include statement into your LocalSettings.php file to include the downloaded UserLoginLog.php file as usual, for example:

include("$IP/extensions/UserLoginLog/UserLoginLog.php");

Note: All MediaWiki logging must be associated with a user, but at the time a login error occurs there is no known user, so the user ID of a user to associate the log by in these cases needs to be specified in the $wgServerUser global variable, eg:

$wgServerUser = 101;

The default ID used is 1, but you can create a user for this like "Nobody", "Wiki" or "Server" and use its ID instead. To find the newly created user's ID, login as the new user and go to the preferences page.

[edit] See also

Personal tools