r51872 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r51871‎ | r51872 | r51873 >
Date:09:47, 15 June 2009
Author:jojo
Status:ok
Tags:
Comment:
rename wgLicense{Name|URL} to wgCollectionLicnse{Name|URL}
Modified paths:
  • /trunk/extensions/Collection/Collection.body.php (modified) (history)
  • /trunk/extensions/Collection/Collection.php (modified) (history)
  • /trunk/extensions/Collection/README.txt (modified) (history)

Diff [purge]

Index: trunk/extensions/Collection/Collection.php
@@ -82,10 +82,10 @@
8383 $wgCollectionMaxArticles = 500;
8484
8585 /** Name of license */
86 -$wgLicenseName = null;
 86+$wgCollectionLicenseName = null;
8787
8888 /** HTTP(s) URL pointing to license in wikitext format: */
89 -$wgLicenseURL = null;
 89+$wgCollectionLicenseURL = null;
9090
9191 /** List of available download formats,
9292 as mapping of mwlib writer to format name */
Index: trunk/extensions/Collection/README.txt
@@ -160,24 +160,24 @@
161161
162162 Default is 500.
163163
164 - *$wgLicenseName (string or null)*
 164+ *$wgCollectionLicenseName (string or null)*
165165 License name for articles in this MediaWiki.
166166 If set to ``null`` the localized version of the word "License" is used.
167167
168168 Default is null.
169169
170 - *$wgLicenseURL (string or null)*
 170+ *$wgCollectionLicenseURL (string or null)*
171171 HTTP URL of an article containing the full license text in wikitext format
172172 for articles in this MediaWiki. E.g.
173173
174 - $wgLicenseURL = 'http://en.wikipedia.org/w/index.php?title=Wikipedia:Text_of_the_GNU_Free_Documentation_License&action=raw';
 174+ $wgCollectionLicenseURL = 'http://en.wikipedia.org/w/index.php?title=Wikipedia:Text_of_the_GNU_Free_Documentation_License&action=raw';
175175
176176 for the GFDL.
177177 If set to null, the standard MediaWiki variables $wgRightsPage,
178178 $wgRightsUrl and $wgRightsText are used for license information.
179179
180180 If your MediaWiki contains articles with different licenses, make sure
181 - that each article contains the name of the license and set $wgLicenseURL
 181+ that each article contains the name of the license and set $wgCollectionLicenseURL
182182 to an article that contains all needed licenses.
183183
184184 * This step is needed for MediaWiki version < 1.14 (at the time of writing
Index: trunk/extensions/Collection/Collection.body.php
@@ -595,8 +595,8 @@
596596 }
597597
598598 function getLicenseInfos() {
599 - global $wgLicenseName;
600 - global $wgLicenseURL;
 599+ global $wgCollectionLicenseName;
 600+ global $wgCollectionLicenseURL;
601601 global $wgRightsIcon;
602602 global $wgRightsPage;
603603 global $wgRightsText;
@@ -614,14 +614,14 @@
615615 return array( $licenseInfo );
616616 }
617617
618 - if ( $wgLicenseName ) {
619 - $licenseInfo['name'] = $wgLicenseName;
 618+ if ( $wgCollectionLicenseName ) {
 619+ $licenseInfo['name'] = $wgCollectionLicenseName;
620620 } else {
621621 $licenseInfo['name'] = wfMsgForContent( 'coll-license' );
622622 }
623623
624 - if ( $wgLicenseURL ) {
625 - $licenseInfo['mw_license_url'] = $wgLicenseURL;
 624+ if ( $wgCollectionLicenseURL ) {
 625+ $licenseInfo['mw_license_url'] = $wgCollectionLicenseURL;
626626 } else {
627627 $licenseInfo['mw_rights_icon'] = $wgRightsIcon;
628628 $licenseInfo['mw_rights_page'] = $wgRightsPage;

Status & tagging log