Index: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsageHooks.php |
— | — | @@ -0,0 +1,78 @@ |
| 2 | +<?php |
| 3 | +class GlobalUsageHooks { |
| 4 | + private static $gu = null; |
| 5 | + |
| 6 | + /** |
| 7 | + * Hook to LinksUpdateComplete |
| 8 | + * Deletes old links from usage table and insert new ones. |
| 9 | + */ |
| 10 | + public static function onLinksUpdateComplete( $linksUpdater ) { |
| 11 | + $title = $linksUpdater->getTitle(); |
| 12 | + |
| 13 | + // Create a list of locally existing images |
| 14 | + $images = array_keys( $linksUpdater->getImages() ); |
| 15 | + $localFiles = array_keys( RepoGroup::singleton()->getLocalRepo()->findFiles( $images ) ); |
| 16 | + |
| 17 | + $gu = self::getGlobalUsage(); |
| 18 | + $gu->deleteFrom( $title->getArticleId( GAID_FOR_UPDATE ) ); |
| 19 | + $gu->setUsage( $title, array_diff( $images, $localFiles ) ); |
| 20 | + |
| 21 | + return true; |
| 22 | + } |
| 23 | + /** |
| 24 | + * Hook to TitleMoveComplete |
| 25 | + * Sets the page title in usage table to the new name. |
| 26 | + */ |
| 27 | + public static function onTitleMoveComplete( $ot, $nt, $user, $pageid, $redirid ) { |
| 28 | + $gu = self::getGlobalUsage(); |
| 29 | + $gu->moveTo( $pageid, $nt ); |
| 30 | + return true; |
| 31 | + } |
| 32 | + /** |
| 33 | + * Hook to ArticleDeleteComplete |
| 34 | + * Deletes entries from usage table. |
| 35 | + * In case of an image, copies the local link table to the global. |
| 36 | + */ |
| 37 | + public static function onArticleDeleteComplete( $article, $user, $reason, $id ) { |
| 38 | + $title = $article->getTitle(); |
| 39 | + $gu = self::getGlobalUsage(); |
| 40 | + $gu->deleteFrom( $id ); |
| 41 | + if ( $title->getNamespace() == NS_FILE ) { |
| 42 | + $gu->copyFromLocal( $title ); |
| 43 | + } |
| 44 | + return true; |
| 45 | + } |
| 46 | + |
| 47 | + /** |
| 48 | + * Hook to FileUndeleteComplete |
| 49 | + * Deletes the file from the global link table. |
| 50 | + */ |
| 51 | + public static function onFileUndeleteComplete( $title, $versions, $user, $reason ) { |
| 52 | + $gu = self::getGlobalUsage(); |
| 53 | + $gu->deleteTo( $title ); |
| 54 | + return true; |
| 55 | + } |
| 56 | + /** |
| 57 | + * Hook to UploadComplete |
| 58 | + * Deletes the file from the global link table. |
| 59 | + */ |
| 60 | + public static function onUploadComplete( $upload ) { |
| 61 | + $gu = self::getGlobalUsage(); |
| 62 | + $gu->deleteTo( $upload->getTitle() ); |
| 63 | + return true; |
| 64 | + } |
| 65 | + |
| 66 | + /** |
| 67 | + * Initializes a GlobalUsage object for the current wiki. |
| 68 | + */ |
| 69 | + private static function getGlobalUsage() { |
| 70 | + global $wgGlobalUsageDatabase; |
| 71 | + if ( is_null( self::$gu ) ) { |
| 72 | + self::$gu = new GlobalUsage( wfWikiId(), |
| 73 | + wfGetDB( DB_MASTER, array(), $wgGlobalUsageDatabase ) |
| 74 | + ); |
| 75 | + } |
| 76 | + |
| 77 | + return self::$gu; |
| 78 | + } |
| 79 | +} |
\ No newline at end of file |
Property changes on: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsageHooks.php |
___________________________________________________________________ |
Name: svn:eol-style |
1 | 80 | + native |
Index: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsage.alias.php |
— | — | @@ -0,0 +1,144 @@ |
| 2 | +<?php |
| 3 | +/** |
| 4 | + * Aliases for special pages |
| 5 | + * |
| 6 | + * @file |
| 7 | + * @ingroup Extensions |
| 8 | + */ |
| 9 | + |
| 10 | +$aliases = array(); |
| 11 | + |
| 12 | +/** English */ |
| 13 | +$aliases['en'] = array( |
| 14 | + 'GlobalUsage' => array( 'GlobalUsage' ), |
| 15 | +); |
| 16 | + |
| 17 | +/** Arabic (العربية) |
| 18 | + * @author Meno25 |
| 19 | + */ |
| 20 | +$aliases['ar'] = array( |
| 21 | + 'GlobalUsage' => array( 'استخدام_عام' ), |
| 22 | +); |
| 23 | + |
| 24 | +/** Egyptian Spoken Arabic (مصرى) |
| 25 | + * @author Meno25 |
| 26 | + */ |
| 27 | +$aliases['arz'] = array( |
| 28 | + 'GlobalUsage' => array( 'استخدام_عام' ), |
| 29 | +); |
| 30 | + |
| 31 | +/** Bosnian (Bosanski) */ |
| 32 | +$aliases['bs'] = array( |
| 33 | + 'GlobalUsage' => array( 'GlobalnaUpotreba' ), |
| 34 | +); |
| 35 | + |
| 36 | +/** German (Deutsch) */ |
| 37 | +$aliases['de'] = array( |
| 38 | + 'GlobalUsage' => array( 'Globale Benutzung' ), |
| 39 | +); |
| 40 | + |
| 41 | +/** Lower Sorbian (Dolnoserbski) */ |
| 42 | +$aliases['dsb'] = array( |
| 43 | + 'GlobalUsage' => array( 'Globalne wužywanje' ), |
| 44 | +); |
| 45 | + |
| 46 | +/** French (Français) */ |
| 47 | +$aliases['fr'] = array( |
| 48 | + 'GlobalUsage' => array( 'Usage global', 'UsageGlobal' ), |
| 49 | +); |
| 50 | + |
| 51 | +/** Franco-Provençal (Arpetan) */ |
| 52 | +$aliases['frp'] = array( |
| 53 | + 'GlobalUsage' => array( 'Usâjo global', 'UsâjoGlobal' ), |
| 54 | +); |
| 55 | + |
| 56 | +/** Galician (Galego) */ |
| 57 | +$aliases['gl'] = array( |
| 58 | + 'GlobalUsage' => array( 'Uso global' ), |
| 59 | +); |
| 60 | + |
| 61 | +/** Swiss German (Alemannisch) */ |
| 62 | +$aliases['gsw'] = array( |
| 63 | + 'GlobalUsage' => array( 'Wältwyti Benutzig' ), |
| 64 | +); |
| 65 | + |
| 66 | +/** Gujarati (ગુજરાતી) */ |
| 67 | +$aliases['gu'] = array( |
| 68 | + 'GlobalUsage' => array( 'વૈશ્વીક વપરાશ' ), |
| 69 | +); |
| 70 | + |
| 71 | +/** Upper Sorbian (Hornjoserbsce) */ |
| 72 | +$aliases['hsb'] = array( |
| 73 | + 'GlobalUsage' => array( 'Globalne wužiwanje' ), |
| 74 | +); |
| 75 | + |
| 76 | +/** Interlingua (Interlingua) */ |
| 77 | +$aliases['ia'] = array( |
| 78 | + 'GlobalUsage' => array( 'Uso global' ), |
| 79 | +); |
| 80 | + |
| 81 | +/** Indonesian (Bahasa Indonesia) */ |
| 82 | +$aliases['id'] = array( |
| 83 | + 'GlobalUsage' => array( 'Penggunaan global', 'PenggunaanGlobal' ), |
| 84 | +); |
| 85 | + |
| 86 | +/** Japanese (日本語) */ |
| 87 | +$aliases['ja'] = array( |
| 88 | + 'GlobalUsage' => array( 'グローバル・ファイル使用状況', 'グローバル使用状況' ), |
| 89 | +); |
| 90 | + |
| 91 | +/** Khmer (ភាសាខ្មែរ) */ |
| 92 | +$aliases['km'] = array( |
| 93 | + 'GlobalUsage' => array( 'បម្រើបម្រាស់ជាសាកល' ), |
| 94 | +); |
| 95 | + |
| 96 | +/** Luxembourgish (Lëtzebuergesch) */ |
| 97 | +$aliases['lb'] = array( |
| 98 | + 'GlobalUsage' => array( 'Globale Gebrauch' ), |
| 99 | +); |
| 100 | + |
| 101 | +/** Malayalam (മലയാളം) */ |
| 102 | +$aliases['ml'] = array( |
| 103 | + 'GlobalUsage' => array( 'ആഗോളഉപയോഗം' ), |
| 104 | +); |
| 105 | + |
| 106 | +/** Maltese (Malti) */ |
| 107 | +$aliases['mt'] = array( |
| 108 | + 'GlobalUsage' => array( 'UżuGlobali' ), |
| 109 | +); |
| 110 | + |
| 111 | +/** Nedersaksisch (Nedersaksisch) */ |
| 112 | +$aliases['nds-nl'] = array( |
| 113 | + 'GlobalUsage' => array( 'Globaal_gebruuk' ), |
| 114 | +); |
| 115 | + |
| 116 | +/** Dutch (Nederlands) */ |
| 117 | +$aliases['nl'] = array( |
| 118 | + 'GlobalUsage' => array( 'GlobaalGebruik' ), |
| 119 | +); |
| 120 | + |
| 121 | +/** Norwegian (bokmål) (Norsk (bokmål)) */ |
| 122 | +$aliases['no'] = array( |
| 123 | + 'GlobalUsage' => array( 'Global bruk' ), |
| 124 | +); |
| 125 | + |
| 126 | +/** Occitan (Occitan) */ |
| 127 | +$aliases['oc'] = array( |
| 128 | + 'GlobalUsage' => array( 'Usatge global', 'UsatgeGlobal' ), |
| 129 | +); |
| 130 | + |
| 131 | +/** Sanskrit (संस्कृत) */ |
| 132 | +$aliases['sa'] = array( |
| 133 | + 'GlobalUsage' => array( 'वैश्विकउपयोग' ), |
| 134 | +); |
| 135 | + |
| 136 | +/** Slovak (Slovenčina) */ |
| 137 | +$aliases['sk'] = array( |
| 138 | + 'GlobalUsage' => array( 'GlobálneVyužitie' ), |
| 139 | +); |
| 140 | + |
| 141 | +/** Tagalog (Tagalog) */ |
| 142 | +$aliases['tl'] = array( |
| 143 | + 'GlobalUsage' => array( 'Pandaigdigang paggamit' ), |
| 144 | +); |
| 145 | + |
Property changes on: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsage.alias.php |
___________________________________________________________________ |
Name: svn:keywords |
1 | 146 | + Id |
Name: svn:eol-style |
2 | 147 | + native |
Index: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsage.sql |
— | — | @@ -0,0 +1,20 @@ |
| 2 | +CREATE TABLE /*$wgDBprefix*/globalimagelinks ( |
| 3 | + -- Wiki id |
| 4 | + gil_wiki varchar(32) not null, |
| 5 | + -- page_id on the local wiki |
| 6 | + gil_page int unsigned not null, |
| 7 | + -- Namespace, since the foreign namespaces may not match the local ones |
| 8 | + gil_page_namespace varchar(255) not null, |
| 9 | + -- Page title |
| 10 | + gil_page_title varchar(255) not null, |
| 11 | + -- Image name |
| 12 | + gil_to varchar(255) not null, |
| 13 | + |
| 14 | + |
| 15 | + -- Note: You might want to shorten the gil_wiki part of the indices. |
| 16 | + -- If the domain format is used, only the "en.wikip" part is needed for an |
| 17 | + -- unique lookup |
| 18 | + |
| 19 | + PRIMARY KEY (gil_to, gil_wiki, gil_page), |
| 20 | + INDEX (gil_wiki, gil_page) |
| 21 | +) /*$wgDBTableOptions*/; |
Property changes on: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsage.sql |
___________________________________________________________________ |
Name: svn:eol-style |
1 | 22 | + native |
Name: svn:eol-style:native |
2 | 23 | + .svn |
Index: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsage.pg.sql |
— | — | @@ -0,0 +1,10 @@ |
| 2 | +CREATE TABLE globalimagelinks ( |
| 3 | + gil_wiki TEXT NOT NULL, |
| 4 | + gil_page INTEGER NOT NULL, |
| 5 | + gil_page_namespace TEXT NOT NULL, |
| 6 | + gil_page_title TEXT NOT NULL, |
| 7 | + gil_to TEXT NOT NULL, |
| 8 | + PRIMARY KEY (gil_to, gil_wiki, gil_page) |
| 9 | +); |
| 10 | +CREATE INDEX globalimagelinks_wiki ON globalimagelinks(gil_wiki, gil_page); |
| 11 | + |
Property changes on: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsage.pg.sql |
___________________________________________________________________ |
Name: svn:eol-style |
1 | 12 | + native |
Index: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsage_body.php |
— | — | @@ -0,0 +1,121 @@ |
| 2 | +<?php |
| 3 | + |
| 4 | +class GlobalUsage { |
| 5 | + private $interwiki; |
| 6 | + private $db; |
| 7 | + |
| 8 | + /** |
| 9 | + * Construct a GlobalUsage instance for a certain wiki. |
| 10 | + * |
| 11 | + * @param $interwiki string Interwiki prefix of the wiki |
| 12 | + * @param $db mixed Database object |
| 13 | + */ |
| 14 | + public function __construct( $interwiki, $db ) { |
| 15 | + $this->interwiki = $interwiki; |
| 16 | + $this->db = $db; |
| 17 | + } |
| 18 | + |
| 19 | + /** |
| 20 | + * Sets the images used by a certain page |
| 21 | + * |
| 22 | + * @param $title Title Title of the page |
| 23 | + * @param $images array Array of db keys of images used |
| 24 | + */ |
| 25 | + public function setUsage( $title, $images ) { |
| 26 | + $insert = array(); |
| 27 | + foreach ( $images as $name ) { |
| 28 | + $insert[] = array( |
| 29 | + 'gil_wiki' => $this->interwiki, |
| 30 | + 'gil_page' => $title->getArticleID( GAID_FOR_UPDATE ), |
| 31 | + 'gil_page_namespace' => $title->getNsText(), |
| 32 | + 'gil_page_title' => $title->getText(), |
| 33 | + 'gil_to' => $name |
| 34 | + ); |
| 35 | + } |
| 36 | + $this->db->insert( 'globalimagelinks', $insert, __METHOD__ ); |
| 37 | + } |
| 38 | + /** |
| 39 | + * Deletes all entries from a certain page |
| 40 | + * |
| 41 | + * @param $id int Page id of the page |
| 42 | + */ |
| 43 | + public function deleteFrom( $id ) { |
| 44 | + $this->db->delete( |
| 45 | + 'globalimagelinks', |
| 46 | + array( |
| 47 | + 'gil_wiki' => $this->interwiki, |
| 48 | + 'gil_page' => $id |
| 49 | + ), |
| 50 | + __METHOD__ |
| 51 | + ); |
| 52 | + } |
| 53 | + /** |
| 54 | + * Deletes all entries to a certain image |
| 55 | + * |
| 56 | + * @param $title Title Title of the file |
| 57 | + */ |
| 58 | + public function deleteTo( $title ) { |
| 59 | + $this->db->delete( |
| 60 | + 'globalimagelinks', |
| 61 | + array( |
| 62 | + 'gil_wiki' => $this->interwiki, |
| 63 | + 'gil_to' => $title->getDBkey() |
| 64 | + ), |
| 65 | + __METHOD__ |
| 66 | + ); |
| 67 | + } |
| 68 | + |
| 69 | + /** |
| 70 | + * Copy local links to global table |
| 71 | + * |
| 72 | + * @param $title Title Title of the file to copy entries from. |
| 73 | + */ |
| 74 | + public function copyFromLocal( $title ) { |
| 75 | + global $wgContLang; |
| 76 | + |
| 77 | + $dbr = wfGetDB( DB_SLAVE ); |
| 78 | + $res = $dbr->select( |
| 79 | + array( 'imagelinks', 'page' ), |
| 80 | + array( 'il_to', 'page_id', 'page_namespace', 'page_title' ), |
| 81 | + array( 'il_from = page_id', 'il_to' => $title->getDBkey() ), |
| 82 | + __METHOD__ |
| 83 | + ); |
| 84 | + $insert = array(); |
| 85 | + foreach ( $res as $row ) { |
| 86 | + $insert[] = array( |
| 87 | + 'gil_wiki' => $this->interwiki, |
| 88 | + 'gil_page' => $row->page_id, |
| 89 | + 'gil_page_namespace' => $wgContLang->getNsText( $row->page_namespace ), |
| 90 | + 'gil_page_title' => $row->page_title, |
| 91 | + 'gil_to' => $row->il_to, |
| 92 | + ); |
| 93 | + } |
| 94 | + $this->db->insert( 'globalimagelinks', $insert, __METHOD__ ); |
| 95 | + } |
| 96 | + |
| 97 | + /** |
| 98 | + * Changes the page title |
| 99 | + * |
| 100 | + * @param $id int Page id of the page |
| 101 | + * @param $title Title New title of the page |
| 102 | + */ |
| 103 | + public function moveTo( $id, $title ) { |
| 104 | + $this->db->update( |
| 105 | + 'globalimagelinks', |
| 106 | + array( |
| 107 | + 'gil_page_namespace' => $title->getNsText(), |
| 108 | + 'gil_page_title' => $title->getText() |
| 109 | + ), |
| 110 | + array( |
| 111 | + 'gil_wiki' => $this->interwiki, |
| 112 | + 'gil_page' => $id |
| 113 | + ), |
| 114 | + __METHOD__ |
| 115 | + ); |
| 116 | + } |
| 117 | + |
| 118 | + |
| 119 | + |
| 120 | + |
| 121 | + |
| 122 | +} |
Property changes on: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsage_body.php |
___________________________________________________________________ |
Name: svn:eol-style |
1 | 123 | + native |
Name: svn:eol-style:native |
2 | 124 | + .svn |
Index: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsage.i18n.php |
— | — | @@ -0,0 +1,959 @@ |
| 2 | +<?php |
| 3 | +/** |
| 4 | + * Internationalisation file for extension GlobalUsage. |
| 5 | + * |
| 6 | + * @addtogroup Extensions |
| 7 | + */ |
| 8 | + |
| 9 | +$messages = array(); |
| 10 | + |
| 11 | +/** English |
| 12 | + * @author Bryan Tong Minh |
| 13 | + */ |
| 14 | +$messages['en'] = array( |
| 15 | + 'globalusage' => 'Global file usage', |
| 16 | + 'globalusage-for' => 'Global usage for "$1"', |
| 17 | + 'globalusage-desc' => '[[Special:GlobalUsage|Special page]] to view global file usage', |
| 18 | + 'globalusage-ok' => 'Search', |
| 19 | + 'globalusage-text' => 'Search global file usage', |
| 20 | + 'globalusage-on-wiki' => 'Usage of [[:File:$1|$1]] on $2', |
| 21 | +); |
| 22 | + |
| 23 | +/** Message documentation (Message documentation) |
| 24 | + * @author Jon Harald Søby |
| 25 | + * @author Purodha |
| 26 | + */ |
| 27 | +$messages['qqq'] = array( |
| 28 | + 'globalusage-desc' => 'Short description of this extension, shown on [[Special:Version]]. Do not translate or change links.', |
| 29 | + 'globalusage-ok' => '{{Identical|Search}}', |
| 30 | +); |
| 31 | + |
| 32 | +/** Karelian (Karjala) |
| 33 | + * @author Flrn |
| 34 | + */ |
| 35 | +$messages['krl'] = array( |
| 36 | + 'globalusage-ok' => 'Ečindy', |
| 37 | +); |
| 38 | + |
| 39 | +/** Niuean (ko e vagahau Niuē) |
| 40 | + * @author Jose77 |
| 41 | + */ |
| 42 | +$messages['niu'] = array( |
| 43 | + 'globalusage-ok' => 'Kumi', |
| 44 | +); |
| 45 | + |
| 46 | +/** Afrikaans (Afrikaans) |
| 47 | + * @author Arnobarnard |
| 48 | + * @author Naudefj |
| 49 | + */ |
| 50 | +$messages['af'] = array( |
| 51 | + 'globalusage' => 'Globale lêergebruik', |
| 52 | + 'globalusage-ok' => 'Soek', |
| 53 | +); |
| 54 | + |
| 55 | +/** Amharic (አማርኛ) |
| 56 | + * @author Codex Sinaiticus |
| 57 | + */ |
| 58 | +$messages['am'] = array( |
| 59 | + 'globalusage-ok' => 'ፍለጋ', |
| 60 | +); |
| 61 | + |
| 62 | +/** Arabic (العربية) |
| 63 | + * @author Alnokta |
| 64 | + * @author Meno25 |
| 65 | + * @author OsamaK |
| 66 | + */ |
| 67 | +$messages['ar'] = array( |
| 68 | + 'globalusage' => 'استخدام الملف العام', |
| 69 | + 'globalusage-for' => 'استخدام "$1" العام', |
| 70 | + 'globalusage-desc' => '[[Special:GlobalUsage|صفحة خاصة]] لرؤية استخدام الملف العام', |
| 71 | + 'globalusage-ok' => 'بحث', |
| 72 | + 'globalusage-text' => 'بحث استخدام الملف العام', |
| 73 | + 'globalusage-on-wiki' => 'استخدام [[:File:$1|$1]] في $2', |
| 74 | +); |
| 75 | + |
| 76 | +/** Aramaic (ܐܪܡܝܐ) |
| 77 | + * @author Basharh |
| 78 | + */ |
| 79 | +$messages['arc'] = array( |
| 80 | + 'globalusage-ok' => 'ܒܨܝ', |
| 81 | +); |
| 82 | + |
| 83 | +/** Egyptian Spoken Arabic (مصرى) |
| 84 | + * @author Meno25 |
| 85 | + */ |
| 86 | +$messages['arz'] = array( |
| 87 | + 'globalusage' => 'استخدام الملف العام', |
| 88 | + 'globalusage-desc' => '[[Special:GlobalUsage|صفحة خاصة]] لرؤية استخدام الملف العام', |
| 89 | + 'globalusage-ok' => 'بحث', |
| 90 | + 'globalusage-text' => 'بحث استخدام الملف العام', |
| 91 | +); |
| 92 | + |
| 93 | +/** Assamese (অসমীয়া) |
| 94 | + * @author Chaipau |
| 95 | + */ |
| 96 | +$messages['as'] = array( |
| 97 | + 'globalusage-ok' => 'সন্ধান কৰক', |
| 98 | +); |
| 99 | + |
| 100 | +/** Bavarian (Boarisch) |
| 101 | + * @author Man77 |
| 102 | + */ |
| 103 | +$messages['bar'] = array( |
| 104 | + 'globalusage' => 'Globale Dateinutzung', |
| 105 | + 'globalusage-desc' => "[[Special:GlobalUsage|Spezialseitn]], de d'globale Vawendung vu dea Datei ãnzoagt", |
| 106 | + 'globalusage-ok' => 'Suacha', |
| 107 | + 'globalusage-text' => 'Globale Suach nåch da Dateivawendung', |
| 108 | +); |
| 109 | + |
| 110 | +/** Belarusian (Taraškievica orthography) (Беларуская (тарашкевіца)) |
| 111 | + * @author EugeneZelenko |
| 112 | + * @author Jim-by |
| 113 | + */ |
| 114 | +$messages['be-tarask'] = array( |
| 115 | + 'globalusage' => 'Глябальнае выкарыстаньне файла', |
| 116 | + 'globalusage-for' => 'Глябальнае выкарыстаньне «$1»', |
| 117 | + 'globalusage-desc' => '[[Special:GlobalUsage|Спэцыяльная старонка]] для прагляду глябальнага выкарыстаньня файла', |
| 118 | + 'globalusage-ok' => 'Пошук', |
| 119 | + 'globalusage-text' => 'Пошук глябальнага выкарыстаньня файла.', |
| 120 | + 'globalusage-on-wiki' => 'Выкарыстаньне [[:File:$1|$1]] у $2', |
| 121 | +); |
| 122 | + |
| 123 | +/** Bulgarian (Български) |
| 124 | + * @author DCLXVI |
| 125 | + */ |
| 126 | +$messages['bg'] = array( |
| 127 | + 'globalusage' => 'Глобално използване на файл', |
| 128 | + 'globalusage-desc' => '[[Special:GlobalUsage|Специална страница]] за преглед на глобалното използване на файл', |
| 129 | + 'globalusage-ok' => 'Търсене', |
| 130 | + 'globalusage-text' => 'Търсене за глобалното използване на файл.', |
| 131 | +); |
| 132 | + |
| 133 | +/** Bengali (বাংলা) |
| 134 | + * @author Zaheen |
| 135 | + */ |
| 136 | +$messages['bn'] = array( |
| 137 | + 'globalusage-ok' => 'অনুসন্ধান', |
| 138 | +); |
| 139 | + |
| 140 | +/** Breton (Brezhoneg) |
| 141 | + * @author Fulup |
| 142 | + */ |
| 143 | +$messages['br'] = array( |
| 144 | + 'globalusage' => 'Implij hollek ar restr', |
| 145 | + 'globalusage-for' => 'Implij hollek evit "$1"', |
| 146 | + 'globalusage-desc' => '[[Special:GlobalUsage|Pajenn dibar]] da welet implij hollek ur skeudenn', |
| 147 | + 'globalusage-ok' => 'Klask', |
| 148 | + 'globalusage-text' => 'Klask implij hollek ar restr', |
| 149 | + 'globalusage-on-wiki' => 'Implij eus [[:File:$1|$1]] war $2', |
| 150 | +); |
| 151 | + |
| 152 | +/** Bosnian (Bosanski) |
| 153 | + * @author CERminator |
| 154 | + */ |
| 155 | +$messages['bs'] = array( |
| 156 | + 'globalusage' => 'Globalna upotreba datoteke', |
| 157 | + 'globalusage-for' => 'Globalna upotreba za "$1"', |
| 158 | + 'globalusage-desc' => '[[Special:GlobalUsage|Posebna stranica]] za pregled globalne upotrebe datoteke', |
| 159 | + 'globalusage-ok' => 'Traži', |
| 160 | + 'globalusage-text' => 'Pretraga globalne upotrebe datoteke.', |
| 161 | + 'globalusage-on-wiki' => 'Upotreba [[:File:$1|$1]] na $2', |
| 162 | +); |
| 163 | + |
| 164 | +/** Catalan (Català) |
| 165 | + * @author Jordi Roqué |
| 166 | + * @author SMP |
| 167 | + */ |
| 168 | +$messages['ca'] = array( |
| 169 | + 'globalusage' => 'Ús global de fitxar', |
| 170 | + 'globalusage-desc' => "[[Special:GlobalUsage|Pàgina especial]] per a veure l'ús global del fitxer", |
| 171 | + 'globalusage-ok' => 'Cerca', |
| 172 | + 'globalusage-text' => "Cerca l'ús global del fitxer.", |
| 173 | +); |
| 174 | + |
| 175 | +/** Chamorro (Chamoru) |
| 176 | + * @author Jatrobat |
| 177 | + */ |
| 178 | +$messages['ch'] = array( |
| 179 | + 'globalusage-ok' => 'Aligao', |
| 180 | +); |
| 181 | + |
| 182 | +/** Church Slavic (Словѣ́ньскъ / ⰔⰎⰑⰂⰡⰐⰠⰔⰍⰟ) |
| 183 | + * @author ОйЛ |
| 184 | + */ |
| 185 | +$messages['cu'] = array( |
| 186 | + 'globalusage-ok' => 'ищи́', |
| 187 | +); |
| 188 | + |
| 189 | +/** Danish (Dansk) |
| 190 | + * @author Jon Harald Søby |
| 191 | + */ |
| 192 | +$messages['da'] = array( |
| 193 | + 'globalusage-ok' => 'Søg', |
| 194 | +); |
| 195 | + |
| 196 | +/** German (Deutsch) |
| 197 | + * @author Raimond Spekking |
| 198 | + * @author Umherirrender |
| 199 | + */ |
| 200 | +$messages['de'] = array( |
| 201 | + 'globalusage' => 'Globale Dateinutzung', |
| 202 | + 'globalusage-for' => 'Globale Dateinutzung für „$1“', |
| 203 | + 'globalusage-desc' => '[[Special:GlobalUsage|Spezialseite]] zur Anzeige, in welchen Projekten die Dateien eines gemeinsam genutzten Repositoriums verwendet werden', |
| 204 | + 'globalusage-ok' => 'Suchen', |
| 205 | + 'globalusage-text' => 'Globale Suche nach Dateinutzungen.', |
| 206 | + 'globalusage-on-wiki' => 'Nutzung von [[:File:$1|$1]] auf $2', |
| 207 | +); |
| 208 | + |
| 209 | +/** Lower Sorbian (Dolnoserbski) |
| 210 | + * @author Michawiki |
| 211 | + */ |
| 212 | +$messages['dsb'] = array( |
| 213 | + 'globalusage' => 'Globalne wužywanje datajow', |
| 214 | + 'globalusage-for' => 'Globalne wužywanje za "$1"', |
| 215 | + 'globalusage-desc' => '[[Special:GlobalUsage|Specialny bok]], aby se globalne wužywanje datajow woglědało', |
| 216 | + 'globalusage-ok' => 'Pytaś', |
| 217 | + 'globalusage-text' => 'Za globalnym wužywanim datajow pytaś', |
| 218 | + 'globalusage-on-wiki' => 'Wužywanje dataje [[:File:$1|$1]] na $2', |
| 219 | +); |
| 220 | + |
| 221 | +/** Greek (Ελληνικά) |
| 222 | + * @author Crazymadlover |
| 223 | + * @author Omnipaedista |
| 224 | + */ |
| 225 | +$messages['el'] = array( |
| 226 | + 'globalusage' => 'Χρήση καθολικού αρχείου', |
| 227 | + 'globalusage-ok' => 'Αναζήτηση', |
| 228 | +); |
| 229 | + |
| 230 | +/** Esperanto (Esperanto) |
| 231 | + * @author Yekrats |
| 232 | + */ |
| 233 | +$messages['eo'] = array( |
| 234 | + 'globalusage' => 'Ĝenerala dosier-uzado', |
| 235 | + 'globalusage-desc' => '[[Special:GlobalUsage|Speciala paĝo]] por rigardi uzadon de ĝeneralaj dosieroj', |
| 236 | + 'globalusage-ok' => 'Serĉi', |
| 237 | + 'globalusage-text' => 'Serĉi uzadon de ĝeneralaj dosieroj.', |
| 238 | +); |
| 239 | + |
| 240 | +/** Spanish (Español) |
| 241 | + * @author Crazymadlover |
| 242 | + * @author Jatrobat |
| 243 | + */ |
| 244 | +$messages['es'] = array( |
| 245 | + 'globalusage' => 'Uso de archivo global', |
| 246 | + 'globalusage-desc' => '[[Special:GlobalUsage|Página especial]] para ver uso de archivo global', |
| 247 | + 'globalusage-ok' => 'Buscar', |
| 248 | + 'globalusage-text' => 'Buscar uso de archivo global', |
| 249 | +); |
| 250 | + |
| 251 | +/** Estonian (Eesti) |
| 252 | + * @author Avjoska |
| 253 | + */ |
| 254 | +$messages['et'] = array( |
| 255 | + 'globalusage' => 'Globaalne failikasutus', |
| 256 | + 'globalusage-ok' => 'Otsi', |
| 257 | + 'globalusage-text' => 'Otsi globaalset failikasutust.', |
| 258 | +); |
| 259 | + |
| 260 | +/** Basque (Euskara) |
| 261 | + * @author Kobazulo |
| 262 | + */ |
| 263 | +$messages['eu'] = array( |
| 264 | + 'globalusage' => 'Fitxategiaren erabilera orokorra', |
| 265 | + 'globalusage-desc' => 'Fitxategiaren erabilera orokorra ikusteko [[Special:GlobalUsage|orrialde berezia]]', |
| 266 | + 'globalusage-ok' => 'Bilatu', |
| 267 | + 'globalusage-text' => 'Fitxategiaren erabilera orokorra bilatu.', |
| 268 | +); |
| 269 | + |
| 270 | +/** Finnish (Suomi) |
| 271 | + * @author ZeiP |
| 272 | + */ |
| 273 | +$messages['fi'] = array( |
| 274 | + 'globalusage-ok' => 'Hae', |
| 275 | +); |
| 276 | + |
| 277 | +/** French (Français) |
| 278 | + * @author Grondin |
| 279 | + * @author IAlex |
| 280 | + * @author Meithal |
| 281 | + * @author PieRRoMaN |
| 282 | + * @author Verdy p |
| 283 | + */ |
| 284 | +$messages['fr'] = array( |
| 285 | + 'globalusage' => 'Usage global du fichier', |
| 286 | + 'globalusage-for' => 'Usage global pour « $1 »', |
| 287 | + 'globalusage-desc' => '[[Special:GlobalUsage|Page spéciale]] pour voir l’usage global d’une image', |
| 288 | + 'globalusage-ok' => 'Rechercher', |
| 289 | + 'globalusage-text' => "Rechercher l'usage global du fichier", |
| 290 | + 'globalusage-on-wiki' => 'Utilisation de [[:File:$1|$1]] sur $2', |
| 291 | +); |
| 292 | + |
| 293 | +/** Western Frisian (Frysk) |
| 294 | + * @author Snakesteuben |
| 295 | + */ |
| 296 | +$messages['fy'] = array( |
| 297 | + 'globalusage-ok' => 'Sykje', |
| 298 | +); |
| 299 | + |
| 300 | +/** Galician (Galego) |
| 301 | + * @author Toliño |
| 302 | + * @author Xosé |
| 303 | + */ |
| 304 | +$messages['gl'] = array( |
| 305 | + 'globalusage' => 'Uso global do ficheiro', |
| 306 | + 'globalusage-for' => 'Uso global de "$1"', |
| 307 | + 'globalusage-desc' => '[[Special:GlobalUsage|Páxina especial]] para ver o uso global do ficheiro', |
| 308 | + 'globalusage-ok' => 'Procurar', |
| 309 | + 'globalusage-text' => 'Procurar o uso global do ficheiro.', |
| 310 | + 'globalusage-on-wiki' => 'Uso de [[:File:$1|$1]] en $2', |
| 311 | +); |
| 312 | + |
| 313 | +/** Ancient Greek (Ἀρχαία ἑλληνικὴ) |
| 314 | + * @author Omnipaedista |
| 315 | + */ |
| 316 | +$messages['grc'] = array( |
| 317 | + 'globalusage-ok' => 'Ζητεῖν', |
| 318 | +); |
| 319 | + |
| 320 | +/** Swiss German (Alemannisch) |
| 321 | + * @author Als-Holder |
| 322 | + */ |
| 323 | +$messages['gsw'] = array( |
| 324 | + 'globalusage' => 'Wältwyti Dateinutzig', |
| 325 | + 'globalusage-for' => 'Wältwyti Verwändig vu „$1“', |
| 326 | + 'globalusage-desc' => '[[Special:GlobalUsage|Spezialsyte]] zu Aazeige, in welene Projäkt d Dateien vun eme gmeinsam gnutzte Repositoriums verwändet wäre', |
| 327 | + 'globalusage-ok' => 'Sueche', |
| 328 | + 'globalusage-text' => 'Wältwyt no Dateinutzige sueche', |
| 329 | + 'globalusage-on-wiki' => 'Gebruch vu [[:File:$1|$1]] uf $2', |
| 330 | +); |
| 331 | + |
| 332 | +/** Gujarati (ગુજરાતી) |
| 333 | + * @author Dineshjk |
| 334 | + */ |
| 335 | +$messages['gu'] = array( |
| 336 | + 'globalusage' => 'ફાઇલનો વ્યાપક ઉપયોગ', |
| 337 | +); |
| 338 | + |
| 339 | +/** Manx (Gaelg) |
| 340 | + * @author MacTire02 |
| 341 | + */ |
| 342 | +$messages['gv'] = array( |
| 343 | + 'globalusage-ok' => 'Ronsaghey', |
| 344 | +); |
| 345 | + |
| 346 | +/** Hakka (Hak-kâ-fa) |
| 347 | + * @author Hakka |
| 348 | + */ |
| 349 | +$messages['hak'] = array( |
| 350 | + 'globalusage-ok' => 'Chhìm-cháu', |
| 351 | +); |
| 352 | + |
| 353 | +/** Hawaiian (Hawai`i) |
| 354 | + * @author Kalani |
| 355 | + */ |
| 356 | +$messages['haw'] = array( |
| 357 | + 'globalusage-ok' => 'Huli', |
| 358 | +); |
| 359 | + |
| 360 | +/** Hebrew (עברית) |
| 361 | + * @author Rotemliss |
| 362 | + * @author YaronSh |
| 363 | + */ |
| 364 | +$messages['he'] = array( |
| 365 | + 'globalusage' => 'שימוש גלובלי בקבצים', |
| 366 | + 'globalusage-for' => 'הקישורים לקובץ "$1" בכל האתרים', |
| 367 | + 'globalusage-desc' => '[[Special:GlobalUsage|דף מיוחד]] להצגת השימוש הגלובלי בקבצים', |
| 368 | + 'globalusage-ok' => 'חיפוש', |
| 369 | + 'globalusage-text' => 'חיפוש בשימוש הגלובלי בקבצים.', |
| 370 | + 'globalusage-on-wiki' => '[[:File:$1|$1]] בשימוש באתר $2', |
| 371 | +); |
| 372 | + |
| 373 | +/** Hindi (हिन्दी) |
| 374 | + * @author Kaustubh |
| 375 | + */ |
| 376 | +$messages['hi'] = array( |
| 377 | + 'globalusage' => 'ग्लोबल फ़ाईल इस्तेमाल', |
| 378 | + 'globalusage-desc' => 'ग्लोबल फ़ाईल इस्तेमाल देखने के लिये [[Special:GlobalUsage|विशेष पॄष्ठ]]', |
| 379 | + 'globalusage-ok' => 'खोजें', |
| 380 | + 'globalusage-text' => 'ग्लोबल फ़ाईल इस्तेमाल खोजें।', |
| 381 | +); |
| 382 | + |
| 383 | +/** Hiligaynon (Ilonggo) |
| 384 | + * @author Jose77 |
| 385 | + */ |
| 386 | +$messages['hil'] = array( |
| 387 | + 'globalusage-ok' => 'Pangita-a', |
| 388 | +); |
| 389 | + |
| 390 | +/** Upper Sorbian (Hornjoserbsce) |
| 391 | + * @author Michawiki |
| 392 | + */ |
| 393 | +$messages['hsb'] = array( |
| 394 | + 'globalusage' => 'Globalne wužiwanje dataje', |
| 395 | + 'globalusage-for' => 'Globalne wužiwanje za "$1"', |
| 396 | + 'globalusage-desc' => '[[Special:GlobalUsage|Specialna strona]], zo by globalne wužiwanje wobraza widźał', |
| 397 | + 'globalusage-ok' => 'Podać', |
| 398 | + 'globalusage-text' => 'Globalne wužiwanje dataje pytać.', |
| 399 | + 'globalusage-on-wiki' => 'Wužiwanje dataje [[:File:$1|$1]] na $2', |
| 400 | +); |
| 401 | + |
| 402 | +/** Hungarian (Magyar) |
| 403 | + * @author Dani |
| 404 | + * @author Glanthor Reviol |
| 405 | + */ |
| 406 | +$messages['hu'] = array( |
| 407 | + 'globalusage' => 'Globális fájl-használat megjelenítése', |
| 408 | + 'globalusage-for' => '„$1” globális használata', |
| 409 | + 'globalusage-desc' => '[[Special:GlobalUsage|Speciális lap]] globális fájlhasználat megjelenítésére', |
| 410 | + 'globalusage-ok' => 'Keresés', |
| 411 | + 'globalusage-text' => 'Fájlhasználat globális keresése', |
| 412 | + 'globalusage-on-wiki' => '[[:File:$1|$1]] használata itt: $2', |
| 413 | +); |
| 414 | + |
| 415 | +/** Armenian (Հայերեն) |
| 416 | + * @author Togaed |
| 417 | + */ |
| 418 | +$messages['hy'] = array( |
| 419 | + 'globalusage-ok' => 'Որոնել', |
| 420 | +); |
| 421 | + |
| 422 | +/** Interlingua (Interlingua) |
| 423 | + * @author McDutchie |
| 424 | + */ |
| 425 | +$messages['ia'] = array( |
| 426 | + 'globalusage' => 'Uso global de files', |
| 427 | + 'globalusage-for' => 'Uso global pro "$1"', |
| 428 | + 'globalusage-desc' => '[[Special:GlobalUsage|Pagina special]] pro vider le uso global de files', |
| 429 | + 'globalusage-ok' => 'Cercar', |
| 430 | + 'globalusage-text' => 'Cercar uso global de files.', |
| 431 | + 'globalusage-on-wiki' => 'Uso de [[:File:$1|$1]] in $2', |
| 432 | +); |
| 433 | + |
| 434 | +/** Indonesian (Bahasa Indonesia) |
| 435 | + * @author Bennylin |
| 436 | + * @author Rex |
| 437 | + */ |
| 438 | +$messages['id'] = array( |
| 439 | + 'globalusage' => 'Penggunaan berkas global', |
| 440 | + 'globalusage-for' => 'Penggunaan global untuk "$1"', |
| 441 | + 'globalusage-desc' => '[[Special:GlobalUsage|Halaman istimewa]] untuk melihat penggunaan berkas secara global', |
| 442 | + 'globalusage-ok' => 'Cari', |
| 443 | + 'globalusage-text' => 'Cari penggunaan berkas secara global.', |
| 444 | + 'globalusage-on-wiki' => 'Penggunaan [[:File:$1|$1]] pada $2', |
| 445 | +); |
| 446 | + |
| 447 | +/** Icelandic (Íslenska) |
| 448 | + * @author S.Örvarr.S |
| 449 | + */ |
| 450 | +$messages['is'] = array( |
| 451 | + 'globalusage-ok' => 'Leita', |
| 452 | +); |
| 453 | + |
| 454 | +/** Italian (Italiano) |
| 455 | + * @author Darth Kule |
| 456 | + */ |
| 457 | +$messages['it'] = array( |
| 458 | + 'globalusage' => 'Utilizzo globale file', |
| 459 | + 'globalusage-desc' => "[[Special:GlobalUsage|Pagina speciale]] per vedere l'utilizzo globale dei file", |
| 460 | + 'globalusage-ok' => 'Ricerca', |
| 461 | + 'globalusage-text' => 'Ricerca utilizzo globale file', |
| 462 | +); |
| 463 | + |
| 464 | +/** Japanese (日本語) |
| 465 | + * @author Fryed-peach |
| 466 | + */ |
| 467 | +$messages['ja'] = array( |
| 468 | + 'globalusage' => 'グローバルなファイル使用状況', |
| 469 | + 'globalusage-for' => '「$1」のグローバルな利用状況', |
| 470 | + 'globalusage-desc' => 'グローバルなファイル使用状況を見るための[[Special:GlobalUsage|特別ページ]]', |
| 471 | + 'globalusage-ok' => '検索', |
| 472 | + 'globalusage-text' => 'グローバルなファイル使用状況を検索する', |
| 473 | + 'globalusage-on-wiki' => '$2での[[:File:$1|$1]]の利用状況', |
| 474 | +); |
| 475 | + |
| 476 | +/** Javanese (Basa Jawa) |
| 477 | + * @author Meursault2004 |
| 478 | + */ |
| 479 | +$messages['jv'] = array( |
| 480 | + 'globalusage' => 'Panggunan berkas sacara global', |
| 481 | + 'globalusage-desc' => '[[Special:GlobalUsage|Kaca astaméwa]] kanggo ndeleng panggunan global berkas', |
| 482 | + 'globalusage-ok' => 'Golèk', |
| 483 | + 'globalusage-text' => 'Golèk panggunan global berkas.', |
| 484 | +); |
| 485 | + |
| 486 | +/** Khmer (ភាសាខ្មែរ) |
| 487 | + * @author Chhorran |
| 488 | + * @author Lovekhmer |
| 489 | + * @author Thearith |
| 490 | + */ |
| 491 | +$messages['km'] = array( |
| 492 | + 'globalusage' => 'បម្រើបម្រាស់ឯកសារជាសាកល', |
| 493 | + 'globalusage-desc' => '[[Special:GlobalUsage|ទំព័រពិសេស]]ដើម្បីមើលបម្រើបម្រាស់ឯកសារជាសាកល', |
| 494 | + 'globalusage-ok' => 'ស្វែងរក', |
| 495 | + 'globalusage-text' => 'ស្វែងរកបម្រើបម្រាស់ឯកសារជាសាកល។', |
| 496 | +); |
| 497 | + |
| 498 | +/** Krio (Krio) |
| 499 | + * @author Jose77 |
| 500 | + */ |
| 501 | +$messages['kri'] = array( |
| 502 | + 'globalusage-ok' => 'Luk foh am', |
| 503 | +); |
| 504 | + |
| 505 | +/** Kinaray-a (Kinaray-a) |
| 506 | + * @author Jose77 |
| 507 | + */ |
| 508 | +$messages['krj'] = array( |
| 509 | + 'globalusage-ok' => 'Sagap', |
| 510 | +); |
| 511 | + |
| 512 | +/** Ripoarisch (Ripoarisch) |
| 513 | + * @author Purodha |
| 514 | + */ |
| 515 | +$messages['ksh'] = array( |
| 516 | + 'globalusage' => 'Jemeinsam jebruch Dateie', |
| 517 | + 'globalusage-for' => 'De Dattei „$1“ weed jemeinsam jebruch', |
| 518 | + 'globalusage-desc' => '[[Special:GlobalUsage|Söndersigg]] för jemeinsam jebruch Dateie ze zeije.', |
| 519 | + 'globalusage-ok' => 'Söhk!', |
| 520 | + 'globalusage-text' => 'Söhk noh jemeinsam jebruch Datteie.', |
| 521 | + 'globalusage-on-wiki' => 'Dä Jebruch vun dä Dattei „[[:File:$1|$1]]“ op $2', |
| 522 | +); |
| 523 | + |
| 524 | +/** Kurdish (Latin) (Kurdî / كوردی (Latin)) |
| 525 | + * @author Bangin |
| 526 | + */ |
| 527 | +$messages['ku-latn'] = array( |
| 528 | + 'globalusage-ok' => 'Lêbigere', |
| 529 | +); |
| 530 | + |
| 531 | +/** Luxembourgish (Lëtzebuergesch) |
| 532 | + * @author Les Meloures |
| 533 | + * @author Robby |
| 534 | + */ |
| 535 | +$messages['lb'] = array( |
| 536 | + 'globalusage' => 'Globaalt Benotze vum Fichier', |
| 537 | + 'globalusage-for' => 'Global Notzung fir "$1"', |
| 538 | + 'globalusage-desc' => "[[Special:GlobalUsage|Spezialsäit]] fir d'globaalt Benotze vun engem Fichier ze gesinn", |
| 539 | + 'globalusage-ok' => 'Sichen', |
| 540 | + 'globalusage-text' => 'Nom globale Benotze vum Fichier sichen.', |
| 541 | + 'globalusage-on-wiki' => 'Notzung vu(n) [[:File:$1|$1]] op $2', |
| 542 | +); |
| 543 | + |
| 544 | +/** Lingua Franca Nova (Lingua Franca Nova) |
| 545 | + * @author Malafaya |
| 546 | + */ |
| 547 | +$messages['lfn'] = array( |
| 548 | + 'globalusage-ok' => 'Xerca', |
| 549 | +); |
| 550 | + |
| 551 | +/** Lithuanian (Lietuvių) |
| 552 | + * @author Homo |
| 553 | + * @author Tomasdd |
| 554 | + */ |
| 555 | +$messages['lt'] = array( |
| 556 | + 'globalusage' => 'Visuotinis failo naudojimas', |
| 557 | + 'globalusage-ok' => 'Ieškoti', |
| 558 | +); |
| 559 | + |
| 560 | +/** Eastern Mari (Олык Марий) |
| 561 | + * @author Сай |
| 562 | + */ |
| 563 | +$messages['mhr'] = array( |
| 564 | + 'globalusage-ok' => 'Кычал', |
| 565 | +); |
| 566 | + |
| 567 | +/** Macedonian (Македонски) |
| 568 | + * @author Bjankuloski06 |
| 569 | + */ |
| 570 | +$messages['mk'] = array( |
| 571 | + 'globalusage' => 'Глобална употреба на податотеки', |
| 572 | + 'globalusage-for' => 'Глобална употреба на „$1“', |
| 573 | + 'globalusage-desc' => '[[Special:GlobalUsage|Специјална страница]] за преглед на употребата на глобални податотеки', |
| 574 | + 'globalusage-ok' => 'Пребарај', |
| 575 | + 'globalusage-text' => 'Пребарување на глобална употреба на податотеки.', |
| 576 | + 'globalusage-on-wiki' => 'Користење на [[:File:$1|$1]] на $2', |
| 577 | +); |
| 578 | + |
| 579 | +/** Malayalam (മലയാളം) |
| 580 | + * @author Shijualex |
| 581 | + */ |
| 582 | +$messages['ml'] = array( |
| 583 | + 'globalusage' => 'പ്രമാണത്തിന്റെ ആഗോള ഉപയോഗം', |
| 584 | + 'globalusage-desc' => 'പ്രമാണത്തിന്റെ ആഗോള ഉപയോഗം കാണിക്കുവാനുള്ള [[Special:GlobalUsage|പ്രത്യേക താള്]]', |
| 585 | + 'globalusage-ok' => 'തിരയൂ', |
| 586 | + 'globalusage-text' => 'പ്രമാണത്തിന്റെ ആഗോള ഉപയോഗം തിരയുക', |
| 587 | +); |
| 588 | + |
| 589 | +/** Mongolian (Монгол) |
| 590 | + * @author Chinneeb |
| 591 | + */ |
| 592 | +$messages['mn'] = array( |
| 593 | + 'globalusage-ok' => 'Хайх', |
| 594 | +); |
| 595 | + |
| 596 | +/** Marathi (मराठी) |
| 597 | + * @author Kaustubh |
| 598 | + * @author Mahitgar |
| 599 | + */ |
| 600 | +$messages['mr'] = array( |
| 601 | + 'globalusage' => 'जागतिक संचिका उपयोग', |
| 602 | + 'globalusage-desc' => '[[Special:GlobalUsage|विशेष पान]] संचिकेच्या उपयोगाचे विस्तृत दृश्य', |
| 603 | + 'globalusage-ok' => 'शोधा', |
| 604 | + 'globalusage-text' => 'जागतिक संचिका उपयोग शोधा.', |
| 605 | +); |
| 606 | + |
| 607 | +/** Erzya (Эрзянь) |
| 608 | + * @author Botuzhaleny-sodamo |
| 609 | + */ |
| 610 | +$messages['myv'] = array( |
| 611 | + 'globalusage-ok' => 'Вешнэмс', |
| 612 | +); |
| 613 | + |
| 614 | +/** Nahuatl (Nāhuatl) |
| 615 | + * @author Fluence |
| 616 | + */ |
| 617 | +$messages['nah'] = array( |
| 618 | + 'globalusage-ok' => 'Titlatēmōz', |
| 619 | +); |
| 620 | + |
| 621 | +/** Dutch (Nederlands) |
| 622 | + * @author Siebrand |
| 623 | + */ |
| 624 | +$messages['nl'] = array( |
| 625 | + 'globalusage' => 'Globaal bestandsgebruik', |
| 626 | + 'globalusage-for' => 'Globaal gebruik voor "$1"', |
| 627 | + 'globalusage-desc' => '[[Special:GlobalUsage|Speciale pagina]] voor het bekijken van globaal bestandsgebruik', |
| 628 | + 'globalusage-ok' => 'Zoeken', |
| 629 | + 'globalusage-text' => 'Globaal bestandsgebruik bekijken', |
| 630 | + 'globalusage-on-wiki' => 'Gebruik van [[:File:$1|$1]] in $2', |
| 631 | +); |
| 632 | + |
| 633 | +/** Norwegian Nynorsk (Norsk (nynorsk)) |
| 634 | + * @author Harald Khan |
| 635 | + * @author Jon Harald Søby |
| 636 | + */ |
| 637 | +$messages['nn'] = array( |
| 638 | + 'globalusage' => 'Global filbruk', |
| 639 | + 'globalusage-desc' => '[[Special:GlobalUsage|Spesialsida]] for å visa bruken av ei fil globalt', |
| 640 | + 'globalusage-ok' => 'Søk', |
| 641 | + 'globalusage-text' => 'Søk global filbruk.', |
| 642 | +); |
| 643 | + |
| 644 | +/** Norwegian (bokmål) (Norsk (bokmål)) |
| 645 | + * @author Jon Harald Søby |
| 646 | + */ |
| 647 | +$messages['no'] = array( |
| 648 | + 'globalusage' => 'Global filbruk', |
| 649 | + 'globalusage-desc' => '[[Special:GlobalUsage|Spesialside]] for å vise bruken av en fil globalt', |
| 650 | + 'globalusage-ok' => 'Søk', |
| 651 | + 'globalusage-text' => 'Søk global filbruk.', |
| 652 | +); |
| 653 | + |
| 654 | +/** Occitan (Occitan) |
| 655 | + * @author Cedric31 |
| 656 | + */ |
| 657 | +$messages['oc'] = array( |
| 658 | + 'globalusage' => 'Usatge global del fichièr', |
| 659 | + 'globalusage-for' => 'Usatge global per « $1 »', |
| 660 | + 'globalusage-desc' => '[[Special:GlobalUsage|Pagina especiala]] per veire l’usatge global d’un imatge', |
| 661 | + 'globalusage-ok' => 'Recèrca', |
| 662 | + 'globalusage-text' => "Recercar l'usatge global del fichièr", |
| 663 | + 'globalusage-on-wiki' => 'Utilizacion de [[:File:$1|$1]] sus $2', |
| 664 | +); |
| 665 | + |
| 666 | +/** Oriya (ଓଡ଼ିଆ) |
| 667 | + * @author Jose77 |
| 668 | + */ |
| 669 | +$messages['or'] = array( |
| 670 | + 'globalusage-ok' => 'ସନ୍ଧାନ', |
| 671 | +); |
| 672 | + |
| 673 | +/** Ossetic (Иронау) |
| 674 | + * @author Amikeco |
| 675 | + */ |
| 676 | +$messages['os'] = array( |
| 677 | + 'globalusage-ok' => 'Агур', |
| 678 | +); |
| 679 | + |
| 680 | +/** Polish (Polski) |
| 681 | + * @author Leinad |
| 682 | + * @author Maikking |
| 683 | + * @author Sp5uhe |
| 684 | + */ |
| 685 | +$messages['pl'] = array( |
| 686 | + 'globalusage' => 'Globalne użycie pliku', |
| 687 | + 'globalusage-for' => 'Globalne użycie „$1”', |
| 688 | + 'globalusage-desc' => '[[Special:GlobalUsage|Strona specjalna]] raportująca globalnie wykorzystanie pliku', |
| 689 | + 'globalusage-ok' => 'Szukaj', |
| 690 | + 'globalusage-text' => 'Globalne wyszukiwanie wykorzystania pliku', |
| 691 | + 'globalusage-on-wiki' => 'Wykorzystanie [[:File:$1|$1]] w {{GRAMMAR:MS.lp:$2}}', |
| 692 | +); |
| 693 | + |
| 694 | +/** Piedmontese (Piemontèis) |
| 695 | + * @author Dragonòt |
| 696 | + */ |
| 697 | +$messages['pms'] = array( |
| 698 | + 'globalusage' => 'Dovragi global dël file', |
| 699 | + 'globalusage-for' => 'Usagi global për "$1"', |
| 700 | + 'globalusage-desc' => '[[Special:GlobalUsage|Pàgina special]] për vëdde ël dovragi global dël file', |
| 701 | + 'globalusage-ok' => 'Serca', |
| 702 | + 'globalusage-text' => 'Serca ël dovragi global dël file.', |
| 703 | + 'globalusage-on-wiki' => 'Usagi ëd [[:File:$1|$1]] dzora $2', |
| 704 | +); |
| 705 | + |
| 706 | +/** Pashto (پښتو) |
| 707 | + * @author Ahmed-Najib-Biabani-Ibrahimkhel |
| 708 | + */ |
| 709 | +$messages['ps'] = array( |
| 710 | + 'globalusage' => 'د نړېوالې دوتنې کارېدنګ', |
| 711 | + 'globalusage-desc' => 'د نړېوالې دوتنې د کارېدنګ د مخليدنې لپاره [[Special:GlobalUsage|ځانګړی مخ]]', |
| 712 | + 'globalusage-ok' => 'پلټل', |
| 713 | + 'globalusage-text' => 'د نړېوالې دوتنې کارېدنګ پلټل', |
| 714 | +); |
| 715 | + |
| 716 | +/** Portuguese (Português) |
| 717 | + * @author Lijealso |
| 718 | + * @author Malafaya |
| 719 | + */ |
| 720 | +$messages['pt'] = array( |
| 721 | + 'globalusage' => 'Utilização global de ficheiro', |
| 722 | + 'globalusage-desc' => '[[Special:GlobalUsage|Página especial]] para consultar a utilização global de ficheiros', |
| 723 | + 'globalusage-ok' => 'Busca', |
| 724 | + 'globalusage-text' => 'Pesquisar utilização global de ficheiro.', |
| 725 | +); |
| 726 | + |
| 727 | +/** Brazilian Portuguese (Português do Brasil) |
| 728 | + * @author Eduardo.mps |
| 729 | + */ |
| 730 | +$messages['pt-br'] = array( |
| 731 | + 'globalusage' => 'Utilização global de arquivos', |
| 732 | + 'globalusage-desc' => '[[Special:GlobalUsage|Página especial]] para consultar a utilização global de arquivos', |
| 733 | + 'globalusage-ok' => 'Busca', |
| 734 | + 'globalusage-text' => 'Pesquisar utilização global de arquivos.', |
| 735 | +); |
| 736 | + |
| 737 | +/** Tarifit (Tarifit) |
| 738 | + * @author Jose77 |
| 739 | + */ |
| 740 | +$messages['rif'] = array( |
| 741 | + 'globalusage-ok' => 'Tarzzut', |
| 742 | +); |
| 743 | + |
| 744 | +/** Romanian (Română) |
| 745 | + * @author KlaudiuMihaila |
| 746 | + */ |
| 747 | +$messages['ro'] = array( |
| 748 | + 'globalusage-ok' => 'Caută', |
| 749 | +); |
| 750 | + |
| 751 | +/** Tarandíne (Tarandíne) |
| 752 | + * @author Joetaras |
| 753 | + */ |
| 754 | +$messages['roa-tara'] = array( |
| 755 | + 'globalusage-ok' => 'Cirche', |
| 756 | +); |
| 757 | + |
| 758 | +/** Russian (Русский) |
| 759 | + * @author Александр Сигачёв |
| 760 | + */ |
| 761 | +$messages['ru'] = array( |
| 762 | + 'globalusage' => 'Глобальное использование файла', |
| 763 | + 'globalusage-for' => 'Глобальное использование «$1»', |
| 764 | + 'globalusage-desc' => '[[Special:GlobalUsage|Служебная страница]] для просмотра общего использования файла', |
| 765 | + 'globalusage-ok' => 'Найти', |
| 766 | + 'globalusage-text' => 'Поиск глобального использования файла.', |
| 767 | + 'globalusage-on-wiki' => 'Использование [[:File:$1|$1]] в $2', |
| 768 | +); |
| 769 | + |
| 770 | +/** Slovak (Slovenčina) |
| 771 | + * @author Helix84 |
| 772 | + */ |
| 773 | +$messages['sk'] = array( |
| 774 | + 'globalusage' => 'Globálne využitie súborov', |
| 775 | + 'globalusage-for' => 'Globálne použitie „$1“', |
| 776 | + 'globalusage-desc' => '[[Special:GlobalUsage|Špeciálna stránka]] na zobrazenie celkového využitia súborov', |
| 777 | + 'globalusage-ok' => 'Hľadať', |
| 778 | + 'globalusage-text' => 'Hľadať globálne využitie súborov.', |
| 779 | + 'globalusage-on-wiki' => 'Použitie [[:File:$1|$1]] na $2', |
| 780 | +); |
| 781 | + |
| 782 | +/** Lower Silesian (Schläsch) |
| 783 | + * @author Jonny84 |
| 784 | + */ |
| 785 | +$messages['sli'] = array( |
| 786 | + 'globalusage' => 'Globale Dateinutzung', |
| 787 | + 'globalusage-desc' => '[[Special:GlobalUsage|Spezialseite]] zur Anzeige, ei welchen Projekten de Dateien eines gemeinsam genutzten Repositoriums verwendet werde', |
| 788 | + 'globalusage-ok' => 'Suchen', |
| 789 | + 'globalusage-text' => 'Globale Suche nach Dateinutzungen.', |
| 790 | +); |
| 791 | + |
| 792 | +/** Serbian Cyrillic ekavian (Српски (ћирилица)) |
| 793 | + * @author Sasa Stefanovic |
| 794 | + * @author Михајло Анђелковић |
| 795 | + */ |
| 796 | +$messages['sr-ec'] = array( |
| 797 | + 'globalusage' => 'Глобално коришћење фајлова', |
| 798 | + 'globalusage-desc' => '[[Special:GlobalUsage|Специјална страна]] за преглед глобалног коришћења фајлова', |
| 799 | + 'globalusage-ok' => 'Претрага', |
| 800 | + 'globalusage-text' => 'Претрага глобалног коришћења фајлова.', |
| 801 | +); |
| 802 | + |
| 803 | +/** Serbian Latin ekavian (Srpski (latinica)) |
| 804 | + * @author Michaello |
| 805 | + */ |
| 806 | +$messages['sr-el'] = array( |
| 807 | + 'globalusage' => 'Globalno korišćenje fajlova', |
| 808 | + 'globalusage-desc' => '[[Special:GlobalUsage|Specijalna strana]] za pregled globalnog korišćenja fajlova', |
| 809 | + 'globalusage-ok' => 'Pretraga', |
| 810 | + 'globalusage-text' => 'Pretraga globalnog korišćenja fajlova.', |
| 811 | +); |
| 812 | + |
| 813 | +/** Seeltersk (Seeltersk) |
| 814 | + * @author Pyt |
| 815 | + */ |
| 816 | +$messages['stq'] = array( |
| 817 | + 'globalusage' => 'Globoale Doatäinutsenge', |
| 818 | + 'globalusage-desc' => '[[Special:GlobalUsage|Spezioalsiede]] toun Anwiesen, in wäkke Projekte do Doatäie fon n gemeensoam nutsed Repositorium ferwoand wäide', |
| 819 | + 'globalusage-ok' => 'Säike', |
| 820 | + 'globalusage-text' => 'Globoale Säike ätter Doatäinutsengen.', |
| 821 | +); |
| 822 | + |
| 823 | +/** Sundanese (Basa Sunda) |
| 824 | + * @author Irwangatot |
| 825 | + */ |
| 826 | +$messages['su'] = array( |
| 827 | + 'globalusage-ok' => 'Sungsi', |
| 828 | +); |
| 829 | + |
| 830 | +/** Swedish (Svenska) |
| 831 | + * @author Lejonel |
| 832 | + * @author M.M.S. |
| 833 | + */ |
| 834 | +$messages['sv'] = array( |
| 835 | + 'globalusage' => 'Global filanvändning', |
| 836 | + 'globalusage-desc' => '[[Special:GlobalUsage|Specialsida]] för att visa på vilka projekt filer från den gemensamma filservern används.', |
| 837 | + 'globalusage-ok' => 'Sök', |
| 838 | + 'globalusage-text' => 'Sök global filanvändning.', |
| 839 | +); |
| 840 | + |
| 841 | +/** Silesian (Ślůnski) |
| 842 | + * @author Herr Kriss |
| 843 | + */ |
| 844 | +$messages['szl'] = array( |
| 845 | + 'globalusage-ok' => 'Šnupej', |
| 846 | +); |
| 847 | + |
| 848 | +/** Tamil (தமிழ்) |
| 849 | + * @author Trengarasu |
| 850 | + */ |
| 851 | +$messages['ta'] = array( |
| 852 | + 'globalusage-ok' => 'தேடுக', |
| 853 | +); |
| 854 | + |
| 855 | +/** Telugu (తెలుగు) |
| 856 | + * @author Veeven |
| 857 | + */ |
| 858 | +$messages['te'] = array( |
| 859 | + 'globalusage' => 'సార్వత్రిక ఫైలు వాడుక', |
| 860 | + 'globalusage-desc' => 'సార్వత్రిక ఫైలు వాడుకని చూడడానికి [[Special:GlobalUsage|ప్రత్యేక పేజీ]]', |
| 861 | + 'globalusage-ok' => 'వెతుకు', |
| 862 | + 'globalusage-text' => 'సార్వత్రిక ఫైళ్ళ వాడుకలో వెతకండి.', |
| 863 | +); |
| 864 | + |
| 865 | +/** Tetum (Tetun) |
| 866 | + * @author MF-Warburg |
| 867 | + */ |
| 868 | +$messages['tet'] = array( |
| 869 | + 'globalusage-ok' => 'Buka', |
| 870 | +); |
| 871 | + |
| 872 | +/** Tajik (Cyrillic) (Тоҷикӣ (Cyrillic)) |
| 873 | + * @author Ibrahim |
| 874 | + */ |
| 875 | +$messages['tg-cyrl'] = array( |
| 876 | + 'globalusage' => 'Истифодаи саросарии парванда', |
| 877 | + 'globalusage-desc' => '[[Special:GlobalUsage|Саҳифаи вижа]] барои дидани истифодаи саросарии парванда', |
| 878 | + 'globalusage-ok' => 'Ҷустуҷӯ', |
| 879 | + 'globalusage-text' => 'Ҷустуҷӯи истифодаи саросарии парванда.', |
| 880 | +); |
| 881 | + |
| 882 | +/** Thai (ไทย) |
| 883 | + * @author Octahedron80 |
| 884 | + */ |
| 885 | +$messages['th'] = array( |
| 886 | + 'globalusage-ok' => 'สืบค้น', |
| 887 | +); |
| 888 | + |
| 889 | +/** Tagalog (Tagalog) |
| 890 | + * @author AnakngAraw |
| 891 | + */ |
| 892 | +$messages['tl'] = array( |
| 893 | + 'globalusage' => 'Paggamit ng pandaigdigang talaksan', |
| 894 | + 'globalusage-desc' => '[[Special:GlobalUsage|Natatanging pahina]] upang makita ang paggamit ng pandaigdigang talaksan', |
| 895 | + 'globalusage-ok' => 'Maghanap', |
| 896 | + 'globalusage-text' => 'Maghanap ng paggamit ng pandaigdigang talaksan.', |
| 897 | +); |
| 898 | + |
| 899 | +/** Turkish (Türkçe) |
| 900 | + * @author Joseph |
| 901 | + */ |
| 902 | +$messages['tr'] = array( |
| 903 | + 'globalusage' => 'Küresel dosya kullanımı', |
| 904 | + 'globalusage-desc' => 'Küresel dosya kullanımını görmek için [[Special:GlobalUsage|özel sayfa]]', |
| 905 | + 'globalusage-ok' => 'Ara', |
| 906 | + 'globalusage-text' => 'Küresel dosya kullanımını ara.', |
| 907 | +); |
| 908 | + |
| 909 | +/** Veps (Vepsan kel') |
| 910 | + * @author Игорь Бродский |
| 911 | + */ |
| 912 | +$messages['vep'] = array( |
| 913 | + 'globalusage-ok' => 'Ectä', |
| 914 | +); |
| 915 | + |
| 916 | +/** Vietnamese (Tiếng Việt) |
| 917 | + * @author Minh Nguyen |
| 918 | + * @author Vinhtantran |
| 919 | + */ |
| 920 | +$messages['vi'] = array( |
| 921 | + 'globalusage' => 'Sử dụng tập tin toàn cục', |
| 922 | + 'globalusage-for' => 'Sử dụng tập tin toàn cục của “$1”', |
| 923 | + 'globalusage-desc' => '[[Special:GlobalUsage|Trang đặc biệt]] để xem tập tin này đang dùng ở đâu trên toàn hệ thống', |
| 924 | + 'globalusage-ok' => 'Tìm kiếm', |
| 925 | + 'globalusage-text' => 'Tìm cách dùng tập tin toàn cục.', |
| 926 | + 'globalusage-on-wiki' => 'Sử dụng [[:File:$1|$1]] tại $2', |
| 927 | +); |
| 928 | + |
| 929 | +/** Volapük (Volapük) |
| 930 | + * @author Smeira |
| 931 | + */ |
| 932 | +$messages['vo'] = array( |
| 933 | + 'globalusage' => 'Ragivigeb Valöpik', |
| 934 | + 'globalusage-desc' => '[[Special:GlobalUsage|Pad patik]] ad logön ragivigebi valöpik', |
| 935 | + 'globalusage-ok' => 'Sukön', |
| 936 | + 'globalusage-text' => 'Sükön ragivigebi valöpik.', |
| 937 | +); |
| 938 | + |
| 939 | +/** Yiddish (ייִדיש) |
| 940 | + * @author פוילישער |
| 941 | + */ |
| 942 | +$messages['yi'] = array( |
| 943 | + 'globalusage-ok' => 'זוכן', |
| 944 | + 'globalusage-text' => 'זוכן גלאבאלע טעקע ניצן.', |
| 945 | +); |
| 946 | + |
| 947 | +/** Simplified Chinese (中文(简体)) |
| 948 | + * @author Gzdavidwong |
| 949 | + */ |
| 950 | +$messages['zh-hans'] = array( |
| 951 | + 'globalusage-ok' => '搜索', |
| 952 | +); |
| 953 | + |
| 954 | +/** Traditional Chinese (中文(繁體)) |
| 955 | + * @author Wrightbus |
| 956 | + */ |
| 957 | +$messages['zh-hant'] = array( |
| 958 | + 'globalusage-ok' => '搜尋', |
| 959 | +); |
| 960 | + |
Property changes on: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsage.i18n.php |
___________________________________________________________________ |
Name: svn:keywords |
1 | 961 | + Id |
Name: svn:eol-style |
2 | 962 | + native |
Index: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsage.php |
— | — | @@ -0,0 +1,72 @@ |
| 2 | +<?php |
| 3 | +/* |
| 4 | + Copyright (c) 2008 - 2009 Bryan Tong Minh |
| 5 | + |
| 6 | + Permission is hereby granted, free of charge, to any person |
| 7 | + obtaining a copy of this software and associated documentation |
| 8 | + files (the "Software"), to deal in the Software without |
| 9 | + restriction, including without limitation the rights to use, |
| 10 | + copy, modify, merge, publish, distribute, sublicense, and/or sell |
| 11 | + copies of the Software, and to permit persons to whom the |
| 12 | + Software is furnished to do so, subject to the following |
| 13 | + conditions: |
| 14 | + |
| 15 | + The above copyright notice and this permission notice shall be |
| 16 | + included in all copies or substantial portions of the Software. |
| 17 | + |
| 18 | + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, |
| 19 | + EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES |
| 20 | + OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND |
| 21 | + NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT |
| 22 | + HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, |
| 23 | + WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING |
| 24 | + FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR |
| 25 | + OTHER DEALINGS IN THE SOFTWARE. |
| 26 | +*/ |
| 27 | + |
| 28 | +// Alert the user that this is not a valid entry point to MediaWiki if they try to access the extension file directly. |
| 29 | +if (!defined('MEDIAWIKI')) { |
| 30 | + echo <<<EOT |
| 31 | +To install my extension, put the following line in LocalSettings.php: |
| 32 | +require_once( "\$IP/extensions/GlobalUsage/GlobalUsage.php" ); |
| 33 | +EOT; |
| 34 | + exit( 1 ); |
| 35 | +} |
| 36 | + |
| 37 | + |
| 38 | +$dir = dirname(__FILE__) . '/'; |
| 39 | + |
| 40 | +$wgExtensionCredits['specialpage'][] = array( |
| 41 | + 'path' => __FILE__, |
| 42 | + 'name' => 'Global Usage', |
| 43 | + 'author' => 'Bryan Tong Minh', |
| 44 | + 'description' => 'Special page to view global file usage', |
| 45 | + 'descriptionmsg' => 'globalusage-desc', |
| 46 | + 'url' => 'http://www.mediawiki.org/wiki/Extension:GlobalUsage', |
| 47 | + 'version' => '2.0', |
| 48 | +); |
| 49 | + |
| 50 | +$wgExtensionMessagesFiles['GlobalUsage'] = $dir . 'GlobalUsage.i18n.php'; |
| 51 | +$wgAutoloadClasses['GlobalUsage'] = $dir . 'GlobalUsage_body.php'; |
| 52 | +$wgAutoloadClasses['GlobalUsageHooks'] = $dir . 'GlobalUsageHooks.php'; |
| 53 | +$wgAutoloadClasses['SpecialGlobalUsage'] = $dir . 'SpecialGlobalUsage.php'; |
| 54 | +$wgExtensionMessageFiles['GlobalUsage'] = $dir . 'GlobalUsage.i18n.php'; |
| 55 | +$wgExtensionAliasesFiles['GlobalUsage'] = $dir . 'GlobalUsage.alias.php'; |
| 56 | +$wgSpecialPages['GlobalUsage'] = 'SpecialGlobalUsage'; |
| 57 | + |
| 58 | +/* Things that can cause link updates: |
| 59 | + * - Local LinksUpdate |
| 60 | + * - Local article deletion (remove from table) |
| 61 | + * - Local article move (update page title) |
| 62 | + * - Local file upload/deletion/move (toggle is_local flag) |
| 63 | + */ |
| 64 | +$wgHooks['LinksUpdateComplete'][] = 'GlobalUsageHooks::onLinksUpdateComplete'; |
| 65 | +$wgHooks['ArticleDeleteComplete'][] = 'GlobalUsageHooks::onArticleDeleteComplete'; |
| 66 | +$wgHooks['FileUndeleteComplete'][] = 'GlobalUsageHooks::onFileUndeleteComplete'; |
| 67 | +$wgHooks['UploadComplete'][] = 'GlobalUsageHooks::onUploadComplete'; |
| 68 | +$wgHooks['TitleMoveComplete'][] = 'GlobalUsageHooks::onTitleMoveComplete'; |
| 69 | + |
| 70 | + |
| 71 | +// If set to false, the local database contains the globalimagelinks table |
| 72 | +// Else set to something understandable to LBFactory |
| 73 | +$wgGlobalUsageDatabase = false; |
Property changes on: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/GlobalUsage.php |
___________________________________________________________________ |
Name: svn:eol-style |
1 | 74 | + native |
Name: svn:eol-style:native |
2 | 75 | + .svn |
Index: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/readme.txt |
— | — | @@ -0,0 +1,16 @@ |
| 2 | +When using a shared image repository, it is impossible to see within MediaWiki |
| 3 | +whether a file is used on one of the slave wikis. On Wikimedia this is handled |
| 4 | +by the CheckUsage tool on the toolserver, but it is merely a hack of function |
| 5 | +that should be built in. |
| 6 | + |
| 7 | +GlobalUsage creates a new table globalimagelinks, which is basically the same |
| 8 | +as imagelinks, but includes the usage of all images on all associated wikis. |
| 9 | + |
| 10 | +The field il_from has been replaced by (gil_wiki, gil_page, gil_page_namespace, |
| 11 | +gil_page_title) which contain respectively the wiki id, page id and page |
| 12 | +namespace name (because they can not be fetched by the shared repo) and title. |
| 13 | + |
| 14 | +The table globalimagelinks actually does not track the usage of links of images |
| 15 | +on the shared repository, but simply all images that do not exist on the local |
| 16 | +wiki. |
| 17 | + |
Property changes on: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/readme.txt |
___________________________________________________________________ |
Name: svn:eol-style |
1 | 18 | + native |
Name: svn:eol-style:native |
2 | 19 | + .svn |
Index: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/SpecialGlobalUsage.php |
— | — | @@ -0,0 +1,211 @@ |
| 2 | +<?php |
| 3 | +/** |
| 4 | + * Crappy ui towards globalimagelinks |
| 5 | + */ |
| 6 | + |
| 7 | +class SpecialGlobalUsage extends SpecialPage { |
| 8 | + public function __construct() { |
| 9 | + parent::__construct( 'GlobalUsage', 'globalusage' ); |
| 10 | + |
| 11 | + wfLoadExtensionMessages( 'globalusage' ); |
| 12 | + } |
| 13 | + |
| 14 | + /** |
| 15 | + * Entry point |
| 16 | + */ |
| 17 | + public function execute( $par ) { |
| 18 | + global $wgOut, $wgRequest; |
| 19 | + |
| 20 | + $target = $par ? $par : $wgRequest->getVal( 'target' ); |
| 21 | + $title = Title::newFromText( $target, NS_FILE ); |
| 22 | + |
| 23 | + $this->setHeaders(); |
| 24 | + |
| 25 | + $this->showForm( $title ); |
| 26 | + |
| 27 | + if ( is_null( $title ) ) |
| 28 | + { |
| 29 | + $wgOut->setPageTitle( wfMsg( 'globalusage' ) ); |
| 30 | + return; |
| 31 | + } |
| 32 | + |
| 33 | + $wgOut->setPageTitle( wfMsg( 'globalusage-for', $title->getPrefixedText() ) ); |
| 34 | + |
| 35 | + $this->showResult( $title ); |
| 36 | + } |
| 37 | + |
| 38 | + /** |
| 39 | + * Shows the search form |
| 40 | + */ |
| 41 | + private function showForm( $title ) { |
| 42 | + global $wgScript, $wgOut; |
| 43 | + |
| 44 | + $html = Xml::openElement( 'form', array( 'action' => $wgScript ) ) . "\n"; |
| 45 | + $html .= Xml::hidden( 'title', $this->getTitle()->getPrefixedText() ) . "\n"; |
| 46 | + $formContent = "\t" . Xml::input( 'target', 40, is_null( $title ) ? '' : $title->getPrefixedText() ) |
| 47 | + . "\n\t" . Xml::element( 'input', array( |
| 48 | + 'type' => 'submit', |
| 49 | + 'value' => wfMsg( 'globalusage-ok' ) |
| 50 | + ) ); |
| 51 | + $html .= Xml::fieldSet( wfMsg( 'globalusage-text' ), $formContent ) . "\n</form>"; |
| 52 | + |
| 53 | + $wgOut->addHtml( $html ); |
| 54 | + } |
| 55 | + |
| 56 | + /** |
| 57 | + * Creates as queryer and executes it based on $wgRequest |
| 58 | + */ |
| 59 | + private function showResult( $target ) { |
| 60 | + global $wgRequest; |
| 61 | + |
| 62 | + $query = new GlobalUsageQuery( $target ); |
| 63 | + |
| 64 | + // Extract params from $wgRequest |
| 65 | + $query->setContinue( $wgRequest->getInt( 'offset', 0 ) ); |
| 66 | + $query->setLimit( $wgRequest->getInt( 'limit', 50 ) ); |
| 67 | + |
| 68 | + // Perform query |
| 69 | + $query->execute(); |
| 70 | + |
| 71 | + // Show result |
| 72 | + global $wgOut; |
| 73 | + |
| 74 | + $navbar = wfViewPrevNext( $query->getOffset(), $query->getLimit(), $this->getTitle(), |
| 75 | + 'target=' . $target->getPrefixedText(), !$query->hasMore() ); |
| 76 | + $targetName = $target->getText(); |
| 77 | + |
| 78 | + $wgOut->addHtml( $navbar ); |
| 79 | + |
| 80 | + foreach ( $query->getResult() as $wiki => $result ) { |
| 81 | + $wgOut->addHtml( |
| 82 | + '<h2>' . wfMsgExt( |
| 83 | + 'globalusage-on-wiki', 'parseinline', |
| 84 | + $targetName, $wiki ) |
| 85 | + . "</h2><ul>\n" ); |
| 86 | + foreach ( $result as $item ) |
| 87 | + $wgOut->addHtml( "\t<li>" . $this->formatItem( $item ) . "</li>\n" ); |
| 88 | + $wgOut->addHtml( "</ul>\n" ); |
| 89 | + } |
| 90 | + |
| 91 | + $wgOut->addHtml( $navbar ); |
| 92 | + } |
| 93 | + /** |
| 94 | + * Helper to format a specific item |
| 95 | + * TODO: Make links |
| 96 | + */ |
| 97 | + private function formatItem( $item ) { |
| 98 | + if ( !$item['namespace'] ) |
| 99 | + $page = $item['title']; |
| 100 | + else |
| 101 | + $page = "{$item['namespace']}:{$item['title']}"; |
| 102 | + |
| 103 | + $wiki = WikiMap::getWiki( $item['wiki'] ); |
| 104 | + |
| 105 | + return WikiMap::makeForeignLink( $item['wiki'], $page ); |
| 106 | + } |
| 107 | + |
| 108 | +} |
| 109 | + |
| 110 | + |
| 111 | + |
| 112 | +/** |
| 113 | + * A helper class to query the globalimagelinks table |
| 114 | + * |
| 115 | + * Should maybe simply resort to offset/limit query rather |
| 116 | + */ |
| 117 | +class GlobalUsageQuery { |
| 118 | + private $limit = 50; |
| 119 | + private $offset = 0; |
| 120 | + private $hasMore = false; |
| 121 | + private $result; |
| 122 | + |
| 123 | + |
| 124 | + public function __construct( $target ) { |
| 125 | + global $wgGlobalUsageDatabase; |
| 126 | + $this->db = wfGetDB( DB_SLAVE, array(), $wgGlobalUsageDatabase ); |
| 127 | + $this->target = $target; |
| 128 | + |
| 129 | + } |
| 130 | + |
| 131 | + /** |
| 132 | + * Set the offset parameter |
| 133 | + * |
| 134 | + * @param $offset int offset |
| 135 | + */ |
| 136 | + public function setContinue( $offset ) { |
| 137 | + $this->offset = $offset; |
| 138 | + } |
| 139 | + /** |
| 140 | + * Return the offset set by the user |
| 141 | + * |
| 142 | + * @return int offset |
| 143 | + */ |
| 144 | + public function getOffset() { |
| 145 | + return $this->offset; |
| 146 | + } |
| 147 | + /** |
| 148 | + * Set the maximum amount of items to return. Capped at 500. |
| 149 | + * |
| 150 | + * @param $limit int The limit |
| 151 | + */ |
| 152 | + public function setLimit( $limit ) { |
| 153 | + $this->limit = min( $limit, 500 ); |
| 154 | + } |
| 155 | + public function getLimit() { |
| 156 | + return $this->limit; |
| 157 | + } |
| 158 | + |
| 159 | + |
| 160 | + /** |
| 161 | + * Executes the query |
| 162 | + */ |
| 163 | + public function execute() { |
| 164 | + $res = $this->db->select( 'globalimagelinks', |
| 165 | + array( |
| 166 | + 'gil_wiki', |
| 167 | + 'gil_page', |
| 168 | + 'gil_page_namespace', |
| 169 | + 'gil_page_title' |
| 170 | + ), |
| 171 | + array( |
| 172 | + 'gil_to' => $this->target->getDBkey() |
| 173 | + ), |
| 174 | + __METHOD__, |
| 175 | + array( |
| 176 | + 'ORDER BY' => 'gil_wiki, gil_page', |
| 177 | + 'LIMIT' => $this->limit + 1, |
| 178 | + 'OFFSET' => $this->offset, |
| 179 | + ) |
| 180 | + ); |
| 181 | + |
| 182 | + $count = 0; |
| 183 | + $this->hasMore = false; |
| 184 | + $this->result = array(); |
| 185 | + foreach ( $res as $row ) { |
| 186 | + $count++; |
| 187 | + if ( $count > $this->limit ) { |
| 188 | + $this->hasMore = true; |
| 189 | + break; |
| 190 | + } |
| 191 | + if ( !isset( $this->result[$row->gil_wiki] ) ) |
| 192 | + $this->result[$row->gil_wiki] = array(); |
| 193 | + $this->result[$row->gil_wiki][] = array( |
| 194 | + 'namespace' => $row->gil_page_namespace, |
| 195 | + 'title' => $row->gil_page_title, |
| 196 | + 'wiki' => $row->gil_wiki, |
| 197 | + ); |
| 198 | + } |
| 199 | + } |
| 200 | + public function getResult() { |
| 201 | + return $this->result; |
| 202 | + } |
| 203 | + |
| 204 | + /** |
| 205 | + * Returns whether there are more results |
| 206 | + * |
| 207 | + * @return bool |
| 208 | + */ |
| 209 | + public function hasMore() { |
| 210 | + return $this->hasMore; |
| 211 | + } |
| 212 | +} |
Property changes on: branches/wmf-deployment/extensions/GlobalUsage/GlobalUsage/SpecialGlobalUsage.php |
___________________________________________________________________ |
Name: svn:eol-style |
1 | 213 | + native |