mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/CategoryTree
synced 2024-11-30 11:06:55 +00:00
* Babel, CategoryTree, MagicNoNumberedHeadings, RegexFunctions and SmoothGallery: new style magic words
* MagicNoNumberedHeadings: add extension description in i18n file, reindent * bump versions where applicable
This commit is contained in:
parent
c1a5082691
commit
cd5deee70b
15
CategoryTree.i18n.magic.php
Normal file
15
CategoryTree.i18n.magic.php
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
<?php
|
||||||
|
/**
|
||||||
|
* Internationalisation file for extension CategoryTree.
|
||||||
|
*
|
||||||
|
* @addtogroup Extensions
|
||||||
|
* @author Daniel Kinzler, brightbyte.de
|
||||||
|
* @copyright © 2006-2008 Daniel Kinzler
|
||||||
|
* @license GNU General Public Licence 2.0 or later
|
||||||
|
*/
|
||||||
|
|
||||||
|
$magicWords = array();
|
||||||
|
|
||||||
|
$magicWords['en'] = array(
|
||||||
|
'categorytree' => array( 0, 'categorytree' ),
|
||||||
|
);
|
|
@ -129,6 +129,11 @@ $wgExtensionCredits['parserhook'][] = array(
|
||||||
* Register the special page
|
* Register the special page
|
||||||
*/
|
*/
|
||||||
$dir = dirname(__FILE__) . '/';
|
$dir = dirname(__FILE__) . '/';
|
||||||
|
|
||||||
|
if ( $wgUseAjax && $wgCategoryTreeAllowTag ) {
|
||||||
|
$wgExtensionMessagesFiles['CategoryTreeMagic'] = $dir . 'CategoryTree.i18n.magic.php';
|
||||||
|
}
|
||||||
|
|
||||||
$wgExtensionMessagesFiles['CategoryTree'] = $dir . 'CategoryTree.i18n.php';
|
$wgExtensionMessagesFiles['CategoryTree'] = $dir . 'CategoryTree.i18n.php';
|
||||||
$wgAutoloadClasses['CategoryTreePage'] = $dir . 'CategoryTreePage.php';
|
$wgAutoloadClasses['CategoryTreePage'] = $dir . 'CategoryTreePage.php';
|
||||||
$wgAutoloadClasses['CategoryTree'] = $dir . 'CategoryTreeFunctions.php';
|
$wgAutoloadClasses['CategoryTree'] = $dir . 'CategoryTreeFunctions.php';
|
||||||
|
@ -137,7 +142,6 @@ $wgSpecialPages['CategoryTree'] = 'CategoryTreePage';
|
||||||
$wgSpecialPageGroups['CategoryTree'] = 'pages';
|
$wgSpecialPageGroups['CategoryTree'] = 'pages';
|
||||||
#$wgHooks['SkinTemplateTabs'][] = 'efCategoryTreeInstallTabs';
|
#$wgHooks['SkinTemplateTabs'][] = 'efCategoryTreeInstallTabs';
|
||||||
$wgHooks['ArticleFromTitle'][] = 'efCategoryTreeArticleFromTitle';
|
$wgHooks['ArticleFromTitle'][] = 'efCategoryTreeArticleFromTitle';
|
||||||
$wgHooks['LanguageGetMagic'][] = 'efCategoryTreeGetMagic';
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* register Ajax function
|
* register Ajax function
|
||||||
|
@ -205,20 +209,6 @@ function efCategoryTreeSetHooks() {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Hook magic word
|
|
||||||
*/
|
|
||||||
function efCategoryTreeGetMagic( &$magicWords, $langCode ) {
|
|
||||||
global $wgUseAjax, $wgCategoryTreeAllowTag;
|
|
||||||
|
|
||||||
if ( $wgUseAjax && $wgCategoryTreeAllowTag ) {
|
|
||||||
//XXX: should we allow a local alias?
|
|
||||||
$magicWords['categorytree'] = array( 0, 'categorytree' );
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Entry point for Ajax, registered in $wgAjaxExportList.
|
* Entry point for Ajax, registered in $wgAjaxExportList.
|
||||||
* The $enc parameter determins how the $options is decoded into a PHP array.
|
* The $enc parameter determins how the $options is decoded into a PHP array.
|
||||||
|
|
Loading…
Reference in a new issue