2007-11-21 16:26:54 +00:00
|
|
|
<?php
|
2009-08-27 13:02:57 +00:00
|
|
|
/**
|
2007-11-21 16:26:54 +00:00
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
2009-08-27 13:02:57 +00:00
|
|
|
* @file
|
|
|
|
* @ingroup Extensions
|
2012-04-15 20:30:03 +00:00
|
|
|
* @version 2.1
|
2007-11-21 16:26:54 +00:00
|
|
|
* @author Stephanie Amanda Stevens <phroziac@gmail.com>
|
2011-07-19 12:45:38 +00:00
|
|
|
* @author Robin Pepermans (SPQRobin) <robinp.1273@gmail.com>
|
2009-08-27 13:02:57 +00:00
|
|
|
* @copyright Copyright © 2005-2007 Stephanie Amanda Stevens
|
2011-07-19 12:45:38 +00:00
|
|
|
* @copyright Copyright © 2007-2011 Robin Pepermans (SPQRobin)
|
2007-11-21 16:26:54 +00:00
|
|
|
* @license http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later
|
2009-08-27 13:02:57 +00:00
|
|
|
* @link http://www.mediawiki.org/wiki/Extension:SpecialInterwiki Documentation
|
2007-11-21 16:26:54 +00:00
|
|
|
* Formatting improvements Stephen Kennedy, 2006.
|
|
|
|
*/
|
|
|
|
|
2012-04-25 08:53:49 +00:00
|
|
|
if ( !defined( 'MEDIAWIKI' ) ) {
|
2009-08-27 13:02:57 +00:00
|
|
|
die( "This is not a valid entry point.\n" );
|
|
|
|
}
|
2007-11-21 16:26:54 +00:00
|
|
|
|
2009-08-27 13:02:57 +00:00
|
|
|
// Extension credits for Special:Version
|
2007-11-21 16:26:54 +00:00
|
|
|
$wgExtensionCredits['specialpage'][] = array(
|
2009-08-27 13:02:57 +00:00
|
|
|
'path' => __FILE__,
|
2012-01-13 09:35:24 +00:00
|
|
|
'name' => 'Interwiki',
|
2011-02-05 23:12:43 +00:00
|
|
|
'author' => array( 'Stephanie Amanda Stevens', 'SPQRobin', '...' ),
|
2012-04-15 20:30:03 +00:00
|
|
|
'version' => '2.1 20120415',
|
2012-01-13 09:35:24 +00:00
|
|
|
'url' => 'https://www.mediawiki.org/wiki/Extension:Interwiki',
|
2008-02-11 13:29:16 +00:00
|
|
|
'descriptionmsg' => 'interwiki-desc',
|
2007-11-21 16:26:54 +00:00
|
|
|
);
|
|
|
|
|
2011-07-19 12:45:38 +00:00
|
|
|
$wgResourceModules['SpecialInterwiki'] = array(
|
2012-04-25 08:53:49 +00:00
|
|
|
'styles' => 'Interwiki.css',
|
|
|
|
'localBasePath' => dirname( __FILE__ ),
|
|
|
|
'remoteExtPath' => 'Interwiki',
|
2011-07-19 12:45:38 +00:00
|
|
|
);
|
|
|
|
|
2009-08-27 13:02:57 +00:00
|
|
|
// Set up the new special page
|
|
|
|
$dir = dirname( __FILE__ ) . '/';
|
2010-04-17 22:52:42 +00:00
|
|
|
$wgExtensionMessagesFiles['Interwiki'] = $dir . 'Interwiki.i18n.php';
|
2011-12-25 23:09:26 +00:00
|
|
|
$wgExtensionMessagesFiles['InterwikiAlias'] = $dir . 'Interwiki.alias.php';
|
2010-04-17 22:52:42 +00:00
|
|
|
$wgAutoloadClasses['SpecialInterwiki'] = $dir . 'Interwiki_body.php';
|
2008-04-03 21:00:22 +00:00
|
|
|
$wgSpecialPages['Interwiki'] = 'SpecialInterwiki';
|
2009-02-10 00:40:30 +00:00
|
|
|
$wgSpecialPageGroups['Interwiki'] = 'wiki';
|
2008-04-03 21:00:22 +00:00
|
|
|
|
2009-08-27 13:02:57 +00:00
|
|
|
// New user right, required to modify the interwiki table through Special:Interwiki
|
2008-05-29 18:38:56 +00:00
|
|
|
$wgAvailableRights[] = 'interwiki';
|
|
|
|
|
2009-08-27 13:02:57 +00:00
|
|
|
// Set up the new log type - interwiki actions are logged to this new log
|
2008-04-03 21:00:22 +00:00
|
|
|
$wgLogTypes[] = 'interwiki';
|
|
|
|
$wgLogNames['interwiki'] = 'interwiki_logpagename';
|
|
|
|
$wgLogHeaders['interwiki'] = 'interwiki_logpagetext';
|
2011-09-26 16:40:05 +00:00
|
|
|
$wgAutoloadClasses['InterwikiLogFormatter'] = $dir . 'Interwiki_body.php';
|
|
|
|
# interwiki, iw_add, iw_delete, iw_edit
|
|
|
|
$wgLogActionsHandlers['interwiki/*'] = 'InterwikiLogFormatter';
|