Merge "Removed clearSharedCache() hack in User.php"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Tue, 15 Sep 2015 12:13:12 +0000 (12:13 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Tue, 15 Sep 2015 12:13:12 +0000 (12:13 +0000)
242 files changed:
.jshintrc
Gruntfile.js
RELEASE-NOTES-1.26
autoload.php
composer.json
includes/DefaultSettings.php
includes/GlobalFunctions.php
includes/HtmlFormatter.php
includes/HttpFunctions.php
includes/Linker.php
includes/MagicWord.php
includes/OutputPage.php
includes/Sanitizer.php
includes/StubObject.php
includes/WikiMap.php
includes/ZhConversion.php
includes/api/ApiBase.php
includes/api/ApiMain.php
includes/api/ApiQueryAllDeletedRevisions.php
includes/api/ApiQueryRandom.php
includes/api/ApiQueryUserInfo.php
includes/api/ApiResult.php
includes/api/i18n/ar.json
includes/api/i18n/de.json
includes/api/i18n/en.json
includes/api/i18n/gl.json
includes/api/i18n/he.json
includes/api/i18n/ja.json
includes/api/i18n/ksh.json
includes/api/i18n/mr.json [new file with mode: 0644]
includes/api/i18n/olo.json [new file with mode: 0644]
includes/api/i18n/pl.json
includes/api/i18n/ps.json
includes/api/i18n/pt.json
includes/api/i18n/qqq.json
includes/api/i18n/ru.json
includes/api/i18n/zh-hans.json
includes/changes/EnhancedChangesList.php
includes/clientpool/RedisConnectionPool.php
includes/filebackend/FileBackend.php
includes/filerepo/file/File.php
includes/installer/i18n/ar.json
includes/installer/i18n/it.json
includes/installer/i18n/ksh.json
includes/installer/i18n/olo.json [new file with mode: 0644]
includes/installer/i18n/pt-br.json
includes/installer/i18n/qqq.json
includes/installer/i18n/yi.json
includes/libs/virtualrest/ParsoidVirtualRESTService.php
includes/libs/virtualrest/RestbaseVirtualRESTService.php
includes/libs/virtualrest/SwiftVirtualRESTService.php
includes/libs/virtualrest/VirtualRESTService.php
includes/media/XMPInfo.php
includes/objectcache/MemcachedPeclBagOStuff.php
includes/objectcache/MemcachedPhpBagOStuff.php
includes/page/ImagePage.php
includes/parser/MWTidy.php
includes/parser/Parser.php
includes/resourceloader/ResourceLoaderFileModule.php
includes/specials/SpecialLinkSearch.php
includes/specials/SpecialListusers.php
includes/specials/SpecialPagesWithProp.php
includes/specials/SpecialUpload.php
includes/specials/SpecialUserlogin.php
includes/templates/Usercreate.php
includes/tidy.conf [deleted file]
includes/tidy/Html5Depurate.php [new file with mode: 0644]
includes/tidy/RaggettBase.php [new file with mode: 0644]
includes/tidy/RaggettExternal.php [new file with mode: 0644]
includes/tidy/RaggettInternalHHVM.php [new file with mode: 0644]
includes/tidy/RaggettInternalPHP.php [new file with mode: 0644]
includes/tidy/RaggettWrapper.php [new file with mode: 0644]
includes/tidy/TidyDriverBase.php [new file with mode: 0644]
includes/tidy/tidy.conf [new file with mode: 0644]
includes/utils/iterators/IteratorDecorator.php
languages/i18n/ady-cyrl.json
languages/i18n/ar.json
languages/i18n/arz.json
languages/i18n/azb.json
languages/i18n/be-tarask.json
languages/i18n/bho.json
languages/i18n/br.json
languages/i18n/ca.json
languages/i18n/ce.json
languages/i18n/ckb.json
languages/i18n/de-formal.json
languages/i18n/de.json
languages/i18n/dty.json
languages/i18n/egl.json
languages/i18n/el.json
languages/i18n/es.json
languages/i18n/et.json
languages/i18n/eu.json
languages/i18n/fa.json
languages/i18n/fr.json
languages/i18n/gl.json
languages/i18n/gom-deva.json
languages/i18n/gom-latn.json
languages/i18n/gsw.json
languages/i18n/gu.json
languages/i18n/hr.json
languages/i18n/ia.json
languages/i18n/id.json
languages/i18n/it.json
languages/i18n/ko.json
languages/i18n/ksh.json
languages/i18n/lad.json
languages/i18n/lrc.json
languages/i18n/lv.json
languages/i18n/mk.json
languages/i18n/ml.json
languages/i18n/mr.json
languages/i18n/mzn.json
languages/i18n/nap.json
languages/i18n/nb.json
languages/i18n/ne.json
languages/i18n/nl.json
languages/i18n/olo.json [new file with mode: 0644]
languages/i18n/pl.json
languages/i18n/pms.json
languages/i18n/ps.json
languages/i18n/pt-br.json
languages/i18n/qqq.json
languages/i18n/roa-tara.json
languages/i18n/ru.json
languages/i18n/scn.json
languages/i18n/sq.json
languages/i18n/sr-ec.json
languages/i18n/sr-el.json
languages/i18n/sv.json
languages/i18n/th.json
languages/i18n/tr.json
languages/i18n/ur.json
languages/i18n/vec.json
languages/i18n/war.json
languages/i18n/wo.json
languages/i18n/yi.json
languages/messages/MessagesKo.php
maintenance/language/zhtable/toCN.manual
maintenance/language/zhtable/toHK.manual
maintenance/language/zhtable/toTW.manual
maintenance/language/zhtable/toTrad.manual
maintenance/language/zhtable/tradphrases.manual
maintenance/language/zhtable/tradphrases_exclude.manual
maintenance/refreshLinks.php
mw-config/images/help-question-hover.gif [new file with mode: 0644]
mw-config/images/help-question.gif [new file with mode: 0644]
package.json
resources/Resources.php
resources/lib/oojs-ui/i18n/ar.json
resources/lib/oojs-ui/i18n/ast.json
resources/lib/oojs-ui/i18n/bn.json
resources/lib/oojs-ui/i18n/es.json
resources/lib/oojs-ui/i18n/et.json
resources/lib/oojs-ui/i18n/eu.json
resources/lib/oojs-ui/i18n/fr.json
resources/lib/oojs-ui/i18n/gl.json
resources/lib/oojs-ui/i18n/ja.json
resources/lib/oojs-ui/i18n/km.json
resources/lib/oojs-ui/i18n/ksh.json
resources/lib/oojs-ui/i18n/lb.json
resources/lib/oojs-ui/i18n/lt.json
resources/lib/oojs-ui/i18n/pl.json
resources/lib/oojs-ui/i18n/ps.json
resources/lib/oojs-ui/i18n/ro.json
resources/lib/oojs-ui/i18n/roa-tara.json
resources/lib/oojs-ui/i18n/ru.json
resources/lib/oojs-ui/i18n/sv.json
resources/lib/oojs-ui/i18n/uk.json
resources/lib/oojs-ui/i18n/vec.json
resources/lib/oojs-ui/i18n/zh-hans.json
resources/lib/oojs-ui/i18n/zh-hant.json
resources/lib/oojs-ui/oojs-ui-apex-noimages.css
resources/lib/oojs-ui/oojs-ui-apex.js
resources/lib/oojs-ui/oojs-ui-mediawiki-noimages.css
resources/lib/oojs-ui/oojs-ui-mediawiki.js
resources/lib/oojs-ui/oojs-ui.js
resources/lib/oojs-ui/themes/mediawiki/images/icons/arched-arrow-ltr-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/arched-arrow-ltr.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/arched-arrow-rtl-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/arched-arrow-rtl.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/bright.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/halfBright.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/largerText-ltr.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/largerText-rtl.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/link-ltr-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/link-ltr.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/menu-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/menu.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/moon.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/notBright.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/quotes-ltr-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/quotes-ltr.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/quotes-rtl-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/quotes-rtl.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/smallerText-ltr.svg
resources/lib/oojs-ui/themes/mediawiki/images/icons/smallerText-rtl.svg
resources/lib/oojs-ui/themes/mediawiki/images/indicators/arrow-down-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/indicators/arrow-down.svg
resources/lib/oojs-ui/themes/mediawiki/images/indicators/arrow-ltr-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/indicators/arrow-ltr.svg
resources/lib/oojs-ui/themes/mediawiki/images/indicators/arrow-rtl-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/indicators/arrow-rtl.svg
resources/lib/oojs-ui/themes/mediawiki/images/indicators/arrow-up-invert.svg
resources/lib/oojs-ui/themes/mediawiki/images/indicators/arrow-up.svg
resources/src/jquery/jquery.tablesorter.js
resources/src/mediawiki.less/mediawiki.mixins.less
resources/src/mediawiki.special/mediawiki.special.userlogin.common.js [deleted file]
resources/src/mediawiki.widgets/mw.widgets.CategorySelector.js [new file with mode: 0644]
resources/src/mediawiki.widgets/mw.widgets.DateInputWidget.js
resources/src/mediawiki.widgets/mw.widgets.DateInputWidget.less
resources/src/mediawiki.widgets/mw.widgets.TitleInputWidget.js
resources/src/mediawiki/mediawiki.Title.js
resources/src/mediawiki/mediawiki.Upload.Dialog.js
resources/src/mediawiki/mediawiki.js
resources/src/mediawiki/mediawiki.util.js
resources/src/startup.js
tests/parser/parserTest.inc
tests/parser/parserTests.txt
tests/phpunit/MediaWikiTestCase.php
tests/phpunit/data/helpers/WellProtectedClass.php
tests/phpunit/includes/ExtraParserTest.php
tests/phpunit/includes/GlobalFunctions/wfUrlencodeTest.php
tests/phpunit/includes/LinkerTest.php
tests/phpunit/includes/OutputPageTest.php
tests/phpunit/includes/SanitizerTest.php
tests/phpunit/includes/TestingAccessWrapper.php
tests/phpunit/includes/TestingAccessWrapperTest.php
tests/phpunit/includes/WikiMapTest.php [new file with mode: 0644]
tests/phpunit/includes/WikiReferenceTest.php [new file with mode: 0644]
tests/phpunit/includes/api/ApiMainTest.php
tests/phpunit/includes/api/ApiResultTest.php
tests/phpunit/includes/content/TextContentHandlerTest.php
tests/phpunit/includes/content/TextContentTest.php
tests/phpunit/includes/objectcache/BagOStuffTest.php
tests/phpunit/includes/parser/NewParserTest.php
tests/phpunit/includes/parser/TagHooksTest.php
tests/phpunit/includes/parser/TidyTest.php
tests/qunit/suites/resources/jquery/jquery.tablesorter.test.js
tests/qunit/suites/resources/mediawiki/mediawiki.Title.test.js
tests/qunit/suites/resources/mediawiki/mediawiki.jqueryMsg.test.js
tests/qunit/suites/resources/mediawiki/mediawiki.util.test.js

index b84d276..b776e8f 100644 (file)
--- a/.jshintrc
+++ b/.jshintrc
@@ -22,7 +22,7 @@
                "mediaWiki": true,
                "JSON": true,
                "OO": true,
-               "performance": true,
+               "mwPerformance": true,
                "jQuery": false,
                "QUnit": false,
                "sinon": false
index 035a208..8dbeb6b 100644 (file)
@@ -32,6 +32,11 @@ module.exports = function ( grunt ) {
                        ]
                },
                banana: {
+                       options: {
+                               disallowBlankTranslations: false,
+                               disallowDuplicateTranslations: false,
+                               disallowUnusedTranslations: false
+                       },
                        core: 'languages/i18n/',
                        api: 'includes/api/i18n/',
                        installer: 'includes/installer/i18n/'
index a532171..8f5db0e 100644 (file)
@@ -29,6 +29,7 @@ production.
 * Fields in ParserOptions are now private. Use the accessors instead.
 * Custom LESS functions (defined via $wgResourceLoaderLESSFunctions)
   have been removed, after being deprecated in 1.24.
+* $wgAlwaysUseTidy has been removed.
 
 === New features in 1.26 ===
 * (T51506) Now action=info gives estimates of actual watchers for a page.
@@ -105,10 +106,22 @@ production.
   sometimes being numerically-indexed objects with formatversion=2.
 * When errors about users being blocked are returned, they now include
   information about the relevant block.
+* (T99926) list=random has higher limits, in line with other API modules.
+* list=random's rnredirect parameter is deprecated in favor of a new
+  rnfilterredir parameter that also allows for listing both redirects and
+  non-redirects.
+* list=random now supports continuation.
+* API responses to GET requests may now include ETag and Last-Modified headers,
+  and will honor corresponding If-None-Match and If-Modified-Since on such
+  requests.
 
 === Action API internal changes in 1.26 ===
 * New metadata item ApiResult::META_KVP_MERGE to allow for merging the KVP key
   into the value when the value is an assoc.
+* API action modules may now provide values for the RFC 7232 ETag and
+  Last-Modified headers. The API will check these against If-None-Match and
+  If-Modified-Since request headers on GET requests and avoid executing the
+  module when appropriate.
 
 === Languages updated in 1.26 ===
 
index 82a45b4..4db3ec7 100644 (file)
@@ -724,7 +724,6 @@ $wgAutoloadLocalClasses = array(
        'MWOldPassword' => __DIR__ . '/includes/password/MWOldPassword.php',
        'MWSaltedPassword' => __DIR__ . '/includes/password/MWSaltedPassword.php',
        'MWTidy' => __DIR__ . '/includes/parser/MWTidy.php',
-       'MWTidyWrapper' => __DIR__ . '/includes/parser/MWTidy.php',
        'MWTimestamp' => __DIR__ . '/includes/MWTimestamp.php',
        'MachineReadableRCFeedFormatter' => __DIR__ . '/includes/rcfeed/MachineReadableRCFeedFormatter.php',
        'MagicWord' => __DIR__ . '/includes/MagicWord.php',
@@ -761,6 +760,13 @@ $wgAutoloadLocalClasses = array(
        'MediaWiki\\Logger\\Monolog\\WikiProcessor' => __DIR__ . '/includes/debug/logger/monolog/WikiProcessor.php',
        'MediaWiki\\Logger\\NullSpi' => __DIR__ . '/includes/debug/logger/NullSpi.php',
        'MediaWiki\\Logger\\Spi' => __DIR__ . '/includes/debug/logger/Spi.php',
+       'MediaWiki\\Tidy\\Html5Depurate' => __DIR__ . '/includes/tidy/Html5Depurate.php',
+       'MediaWiki\\Tidy\\RaggettBase' => __DIR__ . '/includes/tidy/RaggettBase.php',
+       'MediaWiki\\Tidy\\RaggettExternal' => __DIR__ . '/includes/tidy/RaggettExternal.php',
+       'MediaWiki\\Tidy\\RaggettInternalHHVM' => __DIR__ . '/includes/tidy/RaggettInternalHHVM.php',
+       'MediaWiki\\Tidy\\RaggettInternalPHP' => __DIR__ . '/includes/tidy/RaggettInternalPHP.php',
+       'MediaWiki\\Tidy\\RaggettWrapper' => __DIR__ . '/includes/tidy/RaggettWrapper.php',
+       'MediaWiki\\Tidy\\TidyDriverBase' => __DIR__ . '/includes/tidy/TidyDriverBase.php',
        'MediaWiki\\Widget\\ComplexNamespaceInputWidget' => __DIR__ . '/includes/widget/ComplexNamespaceInputWidget.php',
        'MediaWiki\\Widget\\NamespaceInputWidget' => __DIR__ . '/includes/widget/NamespaceInputWidget.php',
        'MediaWiki\\Widget\\TitleInputWidget' => __DIR__ . '/includes/widget/TitleInputWidget.php',
index 4ee78f8..1fe1e50 100644 (file)
                "leafo/lessphp": "0.5.0",
                "liuggio/statsd-php-client": "1.0.16",
                "mediawiki/at-ease": "1.0.0",
-               "oojs/oojs-ui": "0.12.7",
+               "oojs/oojs-ui": "0.12.8",
                "php": ">=5.3.3",
                "psr/log": "1.0.0",
                "wikimedia/assert": "0.2.2",
-               "wikimedia/cdb": "1.2.0",
+               "wikimedia/cdb": "1.3.0",
                "wikimedia/composer-merge-plugin": "1.2.1",
                "wikimedia/ip-set": "1.0.1",
                "wikimedia/utfnormal": "1.0.3",
index 06cd55a..37429b9 100644 (file)
@@ -4104,44 +4104,55 @@ $wgEnableImageWhitelist = true;
 $wgAllowImageTag = false;
 
 /**
- * $wgUseTidy: use tidy to make sure HTML output is sane.
- * Tidy is a free tool that fixes broken HTML.
- * See http://www.w3.org/People/Raggett/tidy/
- *
- * - $wgTidyBin should be set to the path of the binary and
- * - $wgTidyConf to the path of the configuration file.
- * - $wgTidyOpts can include any number of parameters.
- * - $wgTidyInternal controls the use of the PECL extension or the
- *   libtidy (PHP >= 5) extension to use an in-process tidy library instead
- *   of spawning a separate program.
- *   Normally you shouldn't need to override the setting except for
- *   debugging. To install, use 'pear install tidy' and add a line
- *   'extension=tidy.so' to php.ini.
+ * Configuration for HTML postprocessing tool. Set this to a configuration
+ * array to enable an external tool. Dave Raggett's "HTML Tidy" is typically
+ * used. See http://www.w3.org/People/Raggett/tidy/
+ *
+ * If this is null and $wgUseTidy is true, the deprecated configuration
+ * parameters will be used instead.
+ *
+ * If this is null and $wgUseTidy is false, a pure PHP fallback will be used.
+ *
+ * Keys are:
+ *  - driver: May be:
+ *    - RaggettInternalHHVM: Use the limited-functionality HHVM extension
+ *    - RaggettInternalPHP: Use the PECL extension
+ *    - RaggettExternal: Shell out to an external binary (tidyBin)
+ *
+ *  - tidyConfigFile: Path to configuration file for any of the Raggett drivers
+ *  - debugComment: True to add a comment to the output with warning messages
+ *  - tidyBin: For RaggettExternal, the path to the tidy binary.
+ *  - tidyCommandLine: For RaggettExternal, additional command line options.
  */
-$wgUseTidy = false;
+$wgTidyConfig = null;
 
 /**
- * @see $wgUseTidy
+ * Set this to true to use the deprecated tidy configuration parameters.
+ * @deprecated use $wgTidyConfig
  */
-$wgAlwaysUseTidy = false;
+$wgUseTidy = false;
 
 /**
- * @see $wgUseTidy
+ * The path to the tidy binary.
+ * @deprecated Use $wgTidyConfig['tidyBin']
  */
 $wgTidyBin = 'tidy';
 
 /**
- * @see $wgUseTidy
+ * The path to the tidy config file
+ * @deprecated Use $wgTidyConfig['tidyConfigFile']
  */
-$wgTidyConf = $IP . '/includes/tidy.conf';
+$wgTidyConf = $IP . '/includes/tidy/tidy.conf';
 
 /**
- * @see $wgUseTidy
+ * The command line options to the tidy binary
+ * @deprecated Use $wgTidyConfig['tidyCommandLine']
  */
 $wgTidyOpts = '';
 
 /**
- * @see $wgUseTidy
+ * Set this to true to use the tidy extension
+ * @deprecated Use $wgTidyConfig['driver']
  */
 $wgTidyInternal = extension_loaded( 'tidy' );
 
@@ -7225,12 +7236,6 @@ $wgAPIPropModules = array();
  */
 $wgAPIListModules = array();
 
-/**
- * This variable is ignored. To add your module to the API, please add it to $wgAPI*Modules
- * @deprecated since 1.21
- */
-$wgAPIGeneratorModules = array();
-
 /**
  * Maximum amount of rows to scan in a DB query in the API
  * The default value is generally fine
index 68e1635..2852561 100644 (file)
@@ -404,15 +404,14 @@ function wfRandomString( $length = 32 ) {
  * RFC 1738 says ~ is unsafe, however RFC 3986 considers it an unreserved
  * character which should not be encoded. More importantly, google chrome
  * always converts %7E back to ~, and converting it in this function can
- * cause a redirect loop (T105265). Similarly, encoding ' causes a
- * redirect loop on Opera 12 (T106793).
+ * cause a redirect loop (T105265).
  *
  * But + is not safe because it's used to indicate a space; &= are only safe in
- * paths and not in queries (and we don't distinguish here);
- * and urlencode() doesn't touch -_. to begin with.  Plus, although /
+ * paths and not in queries (and we don't distinguish here); ' seems kind of
+ * scary; and urlencode() doesn't touch -_. to begin with.  Plus, although /
  * is reserved, we don't care.  So the list we unescape is:
  *
- * ;:@$!*'(),/~
+ * ;:@$!*(),/~
  *
  * However, IIS7 redirects fail when the url contains a colon (Bug 22709),
  * so no fancy : for IIS7.
@@ -431,7 +430,7 @@ function wfUrlencode( $s ) {
        }
 
        if ( is_null( $needle ) ) {
-               $needle = array( '%3B', '%40', '%24', '%21', '%2A', '%27', '%28', '%29', '%2C', '%2F', '%7E' );
+               $needle = array( '%3B', '%40', '%24', '%21', '%2A', '%28', '%29', '%2C', '%2F', '%7E' );
                if ( !isset( $_SERVER['SERVER_SOFTWARE'] ) ||
                        ( strpos( $_SERVER['SERVER_SOFTWARE'], 'Microsoft-IIS/7' ) === false )
                ) {
@@ -442,7 +441,7 @@ function wfUrlencode( $s ) {
        $s = urlencode( $s );
        $s = str_ireplace(
                $needle,
-               array( ';', '@', '$', '!', '*', '\'', '(', ')', ',', '/', '~', ':' ),
+               array( ';', '@', '$', '!', '*', '(', ')', ',', '/', '~', ':' ),
                $s
        );
 
@@ -2180,14 +2179,24 @@ function wfResetOutputBuffers( $resetGzipEncoding = true ) {
                $wgDisableOutputCompression = true;
        }
        while ( $status = ob_get_status() ) {
-               if ( $status['type'] == 0 /* PHP_OUTPUT_HANDLER_INTERNAL */ ) {
-                       // Probably from zlib.output_compression or other
-                       // PHP-internal setting which can't be removed.
-                       //
+               if ( isset( $status['flags'] ) ) {
+                       $flags = PHP_OUTPUT_HANDLER_CLEANABLE | PHP_OUTPUT_HANDLER_REMOVABLE;
+                       $deleteable = ( $status['flags'] & $flags ) === $flags;
+               } elseif ( isset( $status['del'] ) ) {
+                       $deleteable = $status['del'];
+               } else {
+                       // Guess that any PHP-internal setting can't be removed.
+                       $deleteable = $status['type'] !== 0; /* PHP_OUTPUT_HANDLER_INTERNAL */
+               }
+               if ( !$deleteable ) {
                        // Give up, and hope the result doesn't break
                        // output behavior.
                        break;
                }
+               if ( $status['name'] === 'MediaWikiTestCase::wfResetOutputBuffersBarrier' ) {
+                       // Unit testing barrier to prevent this function from breaking PHPUnit.
+                       break;
+               }
                if ( !ob_end_clean() ) {
                        // Could not remove output buffer handler; abort now
                        // to avoid getting in some kind of infinite loop.
index b2926d1..221cefb 100644 (file)
@@ -63,7 +63,15 @@ class HtmlFormatter {
         */
        public function getDoc() {
                if ( !$this->doc ) {
-                       $html = mb_convert_encoding( $this->html, 'HTML-ENTITIES', 'UTF-8' );
+                       // DOMDocument::loadHTML apparently isn't very good with encodings, so
+                       // convert input to ASCII by encoding everything above 128 as entities.
+                       if ( function_exists( 'mb_convert_encoding' ) ) {
+                               $html = mb_convert_encoding( $this->html, 'HTML-ENTITIES', 'UTF-8' );
+                       } else {
+                               $html = preg_replace_callback( '/[\x{80}-\x{10ffff}]/u', function ( $m ) {
+                                       return '&#' . UtfNormal\Utils::utf8ToCodepoint( $m[0] ) . ';';
+                               }, $this->html );
+                       }
 
                        // Workaround for bug that caused spaces before references
                        // to disappear during processing:
@@ -244,7 +252,14 @@ class HtmlFormatter {
                        ) );
                }
                $html = $replacements->replace( $html );
-               $html = mb_convert_encoding( $html, 'UTF-8', 'HTML-ENTITIES' );
+
+               if ( function_exists( 'mb_convert_encoding' ) ) {
+                       // Just in case the conversion in getDoc() above used named
+                       // entities that aren't known to html_entity_decode().
+                       $html = mb_convert_encoding( $html, 'UTF-8', 'HTML-ENTITIES' );
+               } else {
+                       $html = html_entity_decode( $html, ENT_COMPAT, 'utf-8' );
+               }
                return $html;
        }
 
index 1c79485..bc5a957 100644 (file)
@@ -855,6 +855,8 @@ class CurlHttpRequest extends MWHttpRequest {
 
 class PhpHttpRequest extends MWHttpRequest {
 
+       private $fopenErrors = array();
+
        /**
         * @param string $url
         * @return string
@@ -865,6 +867,60 @@ class PhpHttpRequest extends MWHttpRequest {
                return 'tcp://' . $parsedUrl['host'] . ':' . $parsedUrl['port'];
        }
 
+       /**
+        * Returns an array with a 'capath' or 'cafile' key that is suitable to be merged into the 'ssl' sub-array of a
+        * stream context options array. Uses the 'caInfo' option of the class if it is provided, otherwise uses the system
+        * default CA bundle if PHP supports that, or searches a few standard locations.
+        * @return array
+        * @throws DomainException
+        */
+       protected function getCertOptions() {
+               $certOptions = array();
+               $certLocations = array();
+               if ( $this->caInfo ) {
+                       $certLocations = array( 'manual' => $this->caInfo );
+               } elseif ( version_compare( PHP_VERSION, '5.6.0', '<' ) ) {
+                       // Default locations, based on
+                       // https://www.happyassassin.net/2015/01/12/a-note-about-ssltls-trusted-certificate-stores-and-platforms/
+                       // PHP 5.5 and older doesn't have any defaults, so we try to guess ourselves. PHP 5.6+ gets the CA location
+                       // from OpenSSL as long as it is not set manually, so we should leave capath/cafile empty there.
+                       $certLocations = array_filter( array(
+                               getenv( 'SSL_CERT_DIR' ),
+                               getenv( 'SSL_CERT_PATH' ),
+                               '/etc/pki/tls/certs/ca-bundle.crt', # Fedora et al
+                               '/etc/ssl/certs',  # Debian et al
+                               '/etc/pki/tls/certs/ca-bundle.trust.crt',
+                               '/etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem',
+                               '/System/Library/OpenSSL', # OSX
+                       ) );
+               }
+
+               foreach( $certLocations as $key => $cert ) {
+                       if ( is_dir( $cert ) ) {
+                               $certOptions['capath'] = $cert;
+                               break;
+                       } elseif ( is_file( $cert ) ) {
+                               $certOptions['cafile'] = $cert;
+                               break;
+                       } elseif ( $key === 'manual' ) {
+                               // fail more loudly if a cert path was manually configured and it is not valid
+                               throw new DomainException( "Invalid CA info passed: $cert" );
+                       }
+               }
+
+               return $certOptions;
+       }
+
+       /**
+        * Custom error handler for dealing with fopen() errors. fopen() tends to fire multiple errors in succession, and the last one
+        * is completely useless (something like "fopen: failed to open stream") so normal methods of handling errors programmatically
+        * like get_last_error() don't work.
+        */
+       public function errorHandler( $errno, $errstr ) {
+               $n = count( $this->fopenErrors ) + 1;
+               $this->fopenErrors += array( "errno$n" => $errno, "errstr$n" => $errstr );
+       }
+
        public function execute() {
 
                parent::execute();
@@ -926,13 +982,7 @@ class PhpHttpRequest extends MWHttpRequest {
                        }
                }
 
-               if ( is_dir( $this->caInfo ) ) {
-                       $options['ssl']['capath'] = $this->caInfo;
-               } elseif ( is_file( $this->caInfo ) ) {
-                       $options['ssl']['cafile'] = $this->caInfo;
-               } elseif ( $this->caInfo ) {
-                       throw new MWException( "Invalid CA info passed: {$this->caInfo}" );
-               }
+               $options['ssl'] += $this->getCertOptions();
 
                $context = stream_context_create( $options );
 
@@ -949,9 +999,10 @@ class PhpHttpRequest extends MWHttpRequest {
                }
                do {
                        $reqCount++;
-                       MediaWiki\suppressWarnings();
+                       $this->fopenErrors = array();
+                       set_error_handler( array( $this, 'errorHandler' ) );
                        $fh = fopen( $url, "r", false, $context );
-                       MediaWiki\restoreWarnings();
+                       restore_error_handler();
 
                        if ( !$fh ) {
                                // HACK for instant commons.
@@ -997,6 +1048,10 @@ class PhpHttpRequest extends MWHttpRequest {
                $this->setStatus();
 
                if ( $fh === false ) {
+                       if ( $this->fopenErrors ) {
+                               LoggerFactory::getInstance( 'http' )->warning( __CLASS__
+                                       . ': error opening connection: {errstr1}', $this->fopenErrors );
+                       }
                        $this->status->fatal( 'http-request-error' );
                        return $this->status;
                }
index 4d3f3ce..db6f379 100644 (file)
@@ -939,10 +939,7 @@ class Linker {
 
                        $href = self::getUploadUrl( $title, $query );
 
-                       // @todo FIXME: If we don't to escape apostrophes (single quotes) here (using ENT_QUOTES),
-                       // then double apostrophes will be parsed as italics somewhere later in the parser,
-                       // and break everything horribly
-                       return '<a href="' . htmlspecialchars( $href, ENT_QUOTES ) . '" class="new" title="' .
+                       return '<a href="' . htmlspecialchars( $href ) . '" class="new" title="' .
                                htmlspecialchars( $title->getPrefixedText(), ENT_QUOTES ) . '">' .
                                $encLabel . '</a>';
                }
@@ -1467,7 +1464,7 @@ class Linker {
 
                                                if ( $wikiId !== null ) {
                                                        $thelink = Linker::makeExternalLink(
-                                                               WikiMap::getForeignURL( $wikiId, $target->getFullText() ),
+                                                               WikiMap::getForeignURL( $wikiId, $target->getPrefixedText(), $target->getFragment() ),
                                                                $linkText . $inside,
                                                                /* escape = */ false // Already escaped
                                                        ) . $trail;
index 186821d..833f852 100644 (file)
@@ -718,9 +718,6 @@ class MagicWordArray {
 
        private $regex;
 
-       /** @todo Unused? */
-       private $matches;
-
        /**
         * @param array $names
         */
index 1d1b9fb..552e181 100644 (file)
@@ -2009,21 +2009,20 @@ class OutputPage extends ContextSource {
         * Add an HTTP header that will influence on the cache
         *
         * @param string $header Header name
-        * @param array|null $option
-        * @todo FIXME: Document the $option parameter; it appears to be for
-        *        X-Vary-Options but what format is acceptable?
+        * @param string[]|null $option Options for X-Vary-Options. Possible options are:
+        *  - "string-contains=$XXX" varies on whether the header value as a string
+        *    contains $XXX as a substring.
+        *  - "list-contains=$XXX" varies on whether the header value as a
+        *    comma-separated list contains $XXX as one of the list items.
         */
-       public function addVaryHeader( $header, $option = null ) {
+       public function addVaryHeader( $header, array $option = null ) {
                if ( !array_key_exists( $header, $this->mVaryHeader ) ) {
-                       $this->mVaryHeader[$header] = (array)$option;
-               } elseif ( is_array( $option ) ) {
-                       if ( is_array( $this->mVaryHeader[$header] ) ) {
-                               $this->mVaryHeader[$header] = array_merge( $this->mVaryHeader[$header], $option );
-                       } else {
-                               $this->mVaryHeader[$header] = $option;
-                       }
+                       $this->mVaryHeader[$header] = array();
+               }
+               if ( !is_array( $option ) ) {
+                       $option = array();
                }
-               $this->mVaryHeader[$header] = array_unique( (array)$this->mVaryHeader[$header] );
+               $this->mVaryHeader[$header] = array_unique( array_merge( $this->mVaryHeader[$header], $option ) );
        }
 
        /**
@@ -2906,8 +2905,7 @@ class OutputPage extends ContextSource {
 
                                // Automatically select style/script elements
                                if ( $only === ResourceLoaderModule::TYPE_STYLES ) {
-                                       $media = $group === 'print' ? 'print' : 'all';
-                                       $link = Html::linkedStyle( $url, $media );
+                                       $link = Html::linkedStyle( $url );
                                } else {
                                        if ( $context->getRaw() || $isRaw ) {
                                                // Startup module can't load itself, needs to use <script> instead of mw.loader.load
index 8179905..de63af7 100644 (file)
@@ -454,15 +454,13 @@ class Sanitizer {
        public static function removeHTMLtags( $text, $processCallback = null,
                $args = array(), $extratags = array(), $removetags = array()
        ) {
-               global $wgUseTidy;
-
                extract( self::getRecognizedTagData( $extratags, $removetags ) );
 
                # Remove HTML comments
                $text = Sanitizer::removeHTMLcomments( $text );
                $bits = explode( '<', $text );
                $text = str_replace( '>', '&gt;', array_shift( $bits ) );
-               if ( !$wgUseTidy ) {
+               if ( !MWTidy::isEnabled() ) {
                        $tagstack = $tablestack = array();
                        foreach ( $bits as $x ) {
                                $regs = array();
index 2dfcdc2..49155d6 100644 (file)
@@ -194,7 +194,7 @@ class StubUserLang extends StubObject {
        public function findVariantLink( &$link, &$nt, $ignoreOtherCond = false ) {
                global $wgLang;
                $this->_unstub( 'findVariantLink', 3 );
-               return $wgLang->findVariantLink( $link, $nt, $ignoreOtherCond );
+               $wgLang->findVariantLink( $link, $nt, $ignoreOtherCond );
        }
 
        /**
index f16f5aa..027ff72 100644 (file)
@@ -108,13 +108,15 @@ class WikiMap {
         *
         * @param string $wikiID Wiki'd id (generally database name)
         * @param string $page Page name (must be normalised before calling this function!)
+        * @param string|null $fragmentId
+        *
         * @return string|bool URL or false if the wiki was not found
         */
-       public static function getForeignURL( $wikiID, $page ) {
+       public static function getForeignURL( $wikiID, $page, $fragmentId = null ) {
                $wiki = WikiMap::getWiki( $wikiID );
 
                if ( $wiki ) {
-                       return $wiki->getFullUrl( $page );
+                       return $wiki->getFullUrl( $page, $fragmentId );
                }
 
                return false;
@@ -146,20 +148,6 @@ class WikiReference {
                $this->mServer = $server === null ? $canonicalServer : $server;
        }
 
-       /**
-        * @return string
-        * @throws MWException
-        */
-       public function getHostname() {
-               $prefixes = array( 'http://', 'https://' );
-               foreach ( $prefixes as $prefix ) {
-                       if ( substr( $this->mCanonicalServer, 0, strlen( $prefix ) ) ) {
-                               return substr( $this->mCanonicalServer, strlen( $prefix ) );
-                       }
-               }
-               throw new MWException( "Invalid hostname for wiki {$this->mMinor}.{$this->mMajor}" );
-       }
-
        /**
         * Get the URL in a way to be displayed to the user
         * More or less Wikimedia specific
@@ -167,13 +155,12 @@ class WikiReference {
         * @return string
         */
        public function getDisplayName() {
-               $url = $this->getUrl( '' );
-               $parsed = wfParseUrl( $url );
+               $parsed = wfParseUrl( $this->mCanonicalServer );
                if ( $parsed ) {
                        return $parsed['host'];
                } else {
-                       // Invalid URL. There's no sane thing to do here, so just return it
-                       return $url;
+                       // Invalid server spec. There's no sane thing to do here, so just return the canonical server name in full
+                       return $this->mCanonicalServer;
                }
        }
 
@@ -181,21 +168,32 @@ class WikiReference {
         * Helper function for getUrl()
         *
         * @todo FIXME: This may be generalized...
-        * @param string $page Page name (must be normalised before calling this function!)
-        * @return string Url fragment
+        *
+        * @param string $page Page name (must be normalised before calling this function! May contain a section part.)
+        * @param string|null $fragmentId
+        *
+        * @return string relative URL, without the server part.
         */
-       private function getLocalUrl( $page ) {
-               return str_replace( '$1', wfUrlEncode( str_replace( ' ', '_', $page ) ), $this->mPath );
+       private function getLocalUrl( $page, $fragmentId = null ) {
+               $page = wfUrlEncode( str_replace( ' ', '_', $page ) );
+
+               if ( is_string( $fragmentId ) && $fragmentId !== '' ) {
+                       $page .= '#' . wfUrlEncode( $fragmentId );
+               }
+
+               return str_replace( '$1', $page, $this->mPath );
        }
 
        /**
         * Get a canonical (i.e. based on $wgCanonicalServer) URL to a page on this foreign wiki
         *
         * @param string $page Page name (must be normalised before calling this function!)
+        * @param string|null $fragmentId
+        *
         * @return string Url
         */
-       public function getCanonicalUrl( $page ) {
-               return $this->mCanonicalServer . $this->getLocalUrl( $page );
+       public function getCanonicalUrl( $page, $fragmentId = null ) {
+               return $this->mCanonicalServer . $this->getLocalUrl( $page, $fragmentId );
        }
 
        /**
@@ -209,10 +207,12 @@ class WikiReference {
        /**
         * Alias for getCanonicalUrl(), for backwards compatibility.
         * @param string $page
+        * @param string|null $fragmentId
+        *
         * @return string
         */
-       public function getUrl( $page ) {
-               return $this->getCanonicalUrl( $page );
+       public function getUrl( $page, $fragmentId = null ) {
+               return $this->getCanonicalUrl( $page, $fragmentId );
        }
 
        /**
@@ -220,10 +220,12 @@ class WikiReference {
         * when called locally on the wiki.
         *
         * @param string $page Page name (must be normalized before calling this function!)
+        * @param string|null $fragmentId
+        *
         * @return string URL
         */
-       public function getFullUrl( $page ) {
+       public function getFullUrl( $page, $fragmentId = null ) {
                return $this->mServer .
-                       $this->getLocalUrl( $page );
+                       $this->getLocalUrl( $page, $fragmentId );
        }
 }
index 31806b7..893ae04 100644 (file)
@@ -3074,7 +3074,7 @@ $zh2Hant = array(
 '9只' => '9隻',
 '9余' => '9餘',
 '·范' => '·范',
-'’s ' => '’s',
+'’s' => '’s',
 '、面点' => '、麵點',
 '。个中' => '。箇中',
 '〇周后' => '〇周後',
@@ -3201,21 +3201,6 @@ $zh2Hant = array(
 '不好干预' => '不好干預',
 '不嫌母丑' => '不嫌母醜',
 '不寒而栗' => '不寒而慄',
-'不干事' => '不干事',
-'不干他' => '不干他',
-'不干休' => '不干休',
-'不干你' => '不干你',
-'不干她' => '不干她',
-'不干它' => '不干它',
-'不干我' => '不干我',
-'不干扰' => '不干擾',
-'不干擾' => '不干擾',
-'不干涉' => '不干涉',
-'不干牠' => '不干牠',
-'不干犯' => '不干犯',
-'不干預' => '不干預',
-'不干预' => '不干預',
-'不干' => '不幹',
 '不吊' => '不弔',
 '不卷' => '不捲',
 '不采' => '不採',
@@ -3795,7 +3780,6 @@ $zh2Hant = array(
 '佛罗棱萨' => '佛羅稜薩',
 '佛钟' => '佛鐘',
 '作品里' => '作品裡',
-'作奸犯科' => '作姦犯科',
 '作准' => '作準',
 '你夸' => '你誇',
 '佣金' => '佣金',
@@ -4219,6 +4203,7 @@ $zh2Hant = array(
 '千钧一发' => '千鈞一髮',
 '千只' => '千隻',
 '千余' => '千餘',
+'升高后' => '升高後',
 '半制品' => '半制品',
 '半只可' => '半只可',
 '半只够' => '半只夠',
@@ -4422,6 +4407,7 @@ $zh2Hant = array(
 '呼吁' => '呼籲',
 '命中注定' => '命中注定',
 '和奸' => '和姦',
+'和制汉' => '和製漢',
 '咎征' => '咎徵',
 '咕咕钟' => '咕咕鐘',
 '咪表' => '咪錶',
@@ -4591,9 +4577,12 @@ $zh2Hant = array(
 '墓志' => '墓誌',
 '增辟' => '增闢',
 '墨子里' => '墨子里',
+'墨斗' => '墨斗',
 '墨沈沈' => '墨沈沈',
 '墨沈' => '墨瀋',
 '垦辟' => '墾闢',
+'压制出' => '壓製出',
+'压制机' => '壓製機',
 '壮游' => '壯遊',
 '壮面' => '壯麵',
 '壹郁' => '壹鬱',
@@ -5720,6 +5709,7 @@ $zh2Hant = array(
 '采薇' => '採薇',
 '采薪' => '採薪',
 '采药' => '採藥',
+'采血' => '採血',
 '采行' => '採行',
 '采补' => '採補',
 '采访' => '採訪',
@@ -5746,6 +5736,7 @@ $zh2Hant = array(
 '提子干' => '提子乾',
 '提心吊胆' => '提心弔膽',
 '提摩太后书' => '提摩太後書',
+'提高后' => '提高後',
 '插于' => '插於',
 '换签' => '換籤',
 '换只' => '換隻',
@@ -5944,7 +5935,7 @@ $zh2Hant = array(
 '历始' => '曆始',
 '历室' => '曆室',
 '历尾' => '曆尾',
-'历数' => 'æ\9b\86æ\95¸',
+'历数书' => 'æ\9b\86æ\95¸æ\9b¸',
 '历日' => '曆日',
 '历书' => '曆書',
 '历本' => '曆本',
@@ -6005,6 +5996,7 @@ $zh2Hant = array(
 '望后石' => '望后石',
 '朝乾夕惕' => '朝乾夕惕',
 '朝钟' => '朝鐘',
+'朝鲜于' => '朝鮮於',
 '朦胧' => '朦朧',
 '蒙胧' => '朦朧',
 '木偶戏扎' => '木偶戲紮',
@@ -6305,6 +6297,8 @@ $zh2Hant = array(
 '洗发' => '洗髮',
 '洛钟东应' => '洛鐘東應',
 '洞里' => '洞裡',
+'洞里萨' => '洞里薩',
+'洞里薩' => '洞里薩',
 '泄欲' => '洩慾',
 '洪范' => '洪範',
 '洪谷子' => '洪谷子',
@@ -6376,7 +6370,6 @@ $zh2Hant = array(
 '渠冲' => '渠衝',
 '测不准' => '測不準',
 '港制' => '港製',
-'游牧民族' => '游牧民族',
 '游离' => '游離',
 '浑朴' => '渾樸',
 '浑个' => '渾箇',
@@ -6716,7 +6709,6 @@ $zh2Hant = array(
 '癸丑' => '癸丑',
 '发干' => '發乾',
 '发呆' => '發獃',
-'发蒙' => '發矇',
 '发签' => '發籤',
 '发松' => '發鬆',
 '发面' => '發麵',
@@ -6956,7 +6948,6 @@ $zh2Hant = array(
 '谷草' => '穀草',
 '谷贵饿农' => '穀貴餓農',
 '谷贱伤农' => '穀賤傷農',
-'谷道' => '穀道',
 '谷雨' => '穀雨',
 '谷类' => '穀類',
 '谷食' => '穀食',
@@ -7310,6 +7301,7 @@ $zh2Hant = array(
 '胜肽' => '胜肽',
 '胜键' => '胜鍵',
 '胡云' => '胡云',
+'胡子婴' => '胡子嬰',
 '胡子昂' => '胡子昂',
 '胡杰' => '胡杰',
 '胡朴安' => '胡樸安',
@@ -8959,6 +8951,7 @@ $zh2Hant = array(
 '体范' => '體範',
 '体系' => '體系',
 '高几' => '高几',
+'高后' => '高后',
 '高干扰' => '高干擾',
 '高干预' => '高干預',
 '高干' => '高幹',
@@ -9201,8 +9194,8 @@ $zh2Hant = array(
 '魔表' => '魔錶',
 '鱼干' => '魚乾',
 '鱼松' => '魚鬆',
-'鮮于樞' => '鮮于樞',
-'鲜于枢' => '鮮于樞',
+'鮮于' => '鮮于',
+'鲜于' => '鮮于',
 '鲸须' => '鯨鬚',
 '鳥栖' => '鳥栖',
 '鸟栖市' => '鳥栖市',
@@ -9299,6 +9292,7 @@ $zh2Hant = array(
 '黃杰' => '黃杰',
 '黄杰' => '黃杰',
 '黄历史' => '黃歷史',
+'黄白术' => '黃白術',
 '黃詩杰' => '黃詩杰',
 '黄诗杰' => '黃詩杰',
 '黄金表' => '黃金表',
@@ -13846,8 +13840,6 @@ $zh2TW = array(
 '掌上壓' => '伏地挺身',
 '伯明翰' => '伯明罕',
 '服务器' => '伺服器',
-'字節' => '位元組',
-'字节' => '位元組',
 '佛罗伦萨' => '佛羅倫斯',
 '操作系统' => '作業系統',
 '系数' => '係數',
@@ -14062,6 +14054,7 @@ $zh2TW = array(
 '戒烟' => '戒菸',
 '戒煙' => '戒菸',
 '戴克里先' => '戴克里先',
+'打印度' => '打印度',
 '抽烟' => '抽菸',
 '抽煙' => '抽菸',
 '拉普兰' => '拉布蘭',
@@ -14078,7 +14071,7 @@ $zh2TW = array(
 '搜索引擎' => '搜尋引擎',
 '摩根士丹利' => '摩根史坦利',
 '台球' => '撞球',
-'攻打印' => '攻打印',
+'攻打' => '攻打',
 '数字技术' => '數位技術',
 '數碼技術' => '數位技術',
 '数字照相机' => '數位照相機',
@@ -14129,6 +14122,7 @@ $zh2TW = array(
 '撒切尔' => '柴契爾',
 '格林納達' => '格瑞那達',
 '格林纳达' => '格瑞那達',
+'台式电脑' => '桌上型電腦',
 '乒乓' => '桌球',
 '乒乓球' => '桌球',
 '杆弟' => '桿弟',
@@ -14264,6 +14258,8 @@ $zh2TW = array(
 '弗吉尼亚' => '維吉尼亞',
 '佛得角' => '維德角',
 '维特根斯坦' => '維根斯坦',
+'網絡遊戲' => '網路遊戲',
+'网络游戏' => '網路遊戲',
 '互联网' => '網際網路',
 '互联网络' => '網際網路',
 '互聯網' => '網際網路',
@@ -14455,7 +14451,6 @@ $zh2TW = array(
 '链接' => '連結',
 '連結他' => '連結他',
 '进制' => '進位',
-'算子' => '運算元',
 '达·芬奇' => '達·文西',
 '达芬奇' => '達文西',
 '溫納圖萬' => '那杜',
@@ -15651,6 +15646,7 @@ $zh2HK = array(
 '扛著錄' => '扛著錄',
 '找不著' => '找不着',
 '找得著' => '找得着',
+'承宣布政' => '承宣布政',
 '抓著' => '抓着',
 '抓著作' => '抓著作',
 '抓著名' => '抓著名',
@@ -16001,6 +15997,7 @@ $zh2HK = array(
 '葛萊美獎' => '格林美獎',
 '格鲁吉亚' => '格魯吉亞',
 '框里' => '框裏',
+'台式电脑' => '桌上型電腦',
 '台球' => '桌球',
 '撞球' => '桌球',
 '梅鐸' => '梅鐸',
@@ -17174,6 +17171,8 @@ $zh2HK = array(
 '遇著述' => '遇著述',
 '遇著錄' => '遇著錄',
 '遍布' => '遍佈',
+'遍佈著' => '遍佈着',
+'遍布著' => '遍佈着',
 '過著' => '過着',
 '达·芬奇' => '達·文西',
 '达芬奇' => '達文西',
@@ -18023,6 +18022,7 @@ $zh2CN = array(
 '叫著稱' => '叫著称',
 '叫著者' => '叫著者',
 '叫著述' => '叫著述',
+'桌上型電腦' => '台式电脑',
 '撞球' => '台球',
 '台帳' => '台账',
 '叱吒' => '叱咤',
@@ -19937,6 +19937,8 @@ $zh2CN = array(
 '遇著稱' => '遇著称',
 '遇著者' => '遇著者',
 '遇著述' => '遇著述',
+'遍佈著' => '遍布着',
+'遍布著' => '遍布着',
 '部份' => '部分',
 '配合著' => '配合着',
 '配合著名' => '配合著名',
@@ -19982,6 +19984,7 @@ $zh2CN = array(
 '鋪著稱' => '铺著称',
 '鋪著者' => '铺著者',
 '鋪著述' => '铺著述',
+'鏈結' => '链接',
 '銷帳' => '销账',
 '鉲' => '锎',
 '鎝' => '锝',
index 7b71e6c..d53797b 100644 (file)
@@ -345,6 +345,22 @@ abstract class ApiBase extends ContextSource {
                return null;
        }
 
+       /**
+        * Returns data for HTTP conditional request mechanisms.
+        *
+        * @since 1.26
+        * @param string $condition Condition being queried:
+        *  - last-modified: Return a timestamp representing the maximum of the
+        *    last-modified dates for all resources involved in the request. See
+        *    RFC 7232 § 2.2 for semantics.
+        *  - etag: Return an entity-tag representing the state of all resources involved
+        *    in the request. Quotes must be included. See RFC 7232 § 2.3 for semantics.
+        * @return string|boolean|null As described above, or null if no value is available.
+        */
+       public function getConditionalRequestData( $condition ) {
+               return null;
+       }
+
        /**@}*/
 
        /************************************************************************//**
index f2059d7..c558c2b 100644 (file)
@@ -425,13 +425,16 @@ class ApiMain extends ApiBase {
 
                // In case an error occurs during data output,
                // clear the output buffer and print just the error information
+               $obLevel = ob_get_level();
                ob_start();
 
                $t = microtime( true );
                try {
                        $this->executeAction();
+                       $isError = false;
                } catch ( Exception $e ) {
                        $this->handleException( $e );
+                       $isError = true;
                }
 
                // Log the request whether or not there was an error
@@ -439,9 +442,13 @@ class ApiMain extends ApiBase {
 
                // Send cache headers after any code which might generate an error, to
                // avoid sending public cache headers for errors.
-               $this->sendCacheHeaders();
+               $this->sendCacheHeaders( $isError );
 
-               ob_end_flush();
+               // Executing the action might have already messed with the output
+               // buffers.
+               while ( ob_get_level() > $obLevel ) {
+                       ob_end_flush();
+               }
        }
 
        /**
@@ -532,7 +539,7 @@ class ApiMain extends ApiBase {
 
                // Log the request and reset cache headers
                $main->logRequest( 0 );
-               $main->sendCacheHeaders();
+               $main->sendCacheHeaders( true );
 
                ob_end_flush();
        }
@@ -701,7 +708,12 @@ class ApiMain extends ApiBase {
                return "/^https?:\/\/$wildcard$/";
        }
 
-       protected function sendCacheHeaders() {
+       /**
+        * Send caching headers
+        * @param boolean $isError Whether an error response is being output
+        * @since 1.26 added $isError parameter
+        */
+       protected function sendCacheHeaders( $isError ) {
                $response = $this->getRequest()->response();
                $out = $this->getOutput();
 
@@ -711,6 +723,19 @@ class ApiMain extends ApiBase {
                        $out->addVaryHeader( 'X-Forwarded-Proto' );
                }
 
+               if ( !$isError && $this->mModule &&
+                       ( $this->getRequest()->getMethod() === 'GET' || $this->getRequest()->getMethod() === 'HEAD' )
+               ) {
+                       $etag = $this->mModule->getConditionalRequestData( 'etag' );
+                       if ( $etag !== null ) {
+                               $response->header( "ETag: $etag" );
+                       }
+                       $lastMod = $this->mModule->getConditionalRequestData( 'last-modified' );
+                       if ( $lastMod !== null ) {
+                               $response->header( 'Last-Modified: ' . wfTimestamp( TS_RFC2822, $lastMod ) );
+                       }
+               }
+
                // The logic should be:
                // $this->mCacheControl['max-age'] is set?
                //    Use it, the module knows better than our guess.
@@ -993,6 +1018,121 @@ class ApiMain extends ApiBase {
                return true;
        }
 
+       /**
+        * Check selected RFC 7232 precondition headers
+        *
+        * RFC 7232 envisions a particular model where you send your request to "a
+        * resource", and for write requests that you can read "the resource" by
+        * changing the method to GET. When the API receives a GET request, it
+        * works out even though "the resource" from RFC 7232's perspective might
+        * be many resources from MediaWiki's perspective. But it totally fails for
+        * a POST, since what HTTP sees as "the resource" is probably just
+        * "/api.php" with all the interesting bits in the body.
+        *
+        * Therefore, we only support RFC 7232 precondition headers for GET (and
+        * HEAD). That means we don't need to bother with If-Match and
+        * If-Unmodified-Since since they only apply to modification requests.
+        *
+        * And since we don't support Range, If-Range is ignored too.
+        *
+        * @since 1.26
+        * @param ApiBase $module Api module being used
+        * @return bool True on success, false should exit immediately
+        */
+       protected function checkConditionalRequestHeaders( $module ) {
+               if ( $this->mInternalMode ) {
+                       // No headers to check in internal mode
+                       return true;
+               }
+
+               if ( $this->getRequest()->getMethod() !== 'GET' && $this->getRequest()->getMethod() !== 'HEAD' ) {
+                       // Don't check POSTs
+                       return true;
+               }
+
+               $return304 = false;
+
+               $ifNoneMatch = array_diff(
+                       $this->getRequest()->getHeader( 'If-None-Match', WebRequest::GETHEADER_LIST ) ?: array(),
+                       array( '' )
+               );
+               if ( $ifNoneMatch ) {
+                       if ( $ifNoneMatch === array( '*' ) ) {
+                               // API responses always "exist"
+                               $etag = '*';
+                       } else {
+                               $etag = $module->getConditionalRequestData( 'etag' );
+                       }
+               }
+               if ( $ifNoneMatch && $etag !== null ) {
+                       $test = substr( $etag, 0, 2 ) === 'W/' ? substr( $etag, 2 ) : $etag;
+                       $match = array_map( function ( $s ) {
+                               return substr( $s, 0, 2 ) === 'W/' ? substr( $s, 2 ) : $s;
+                       }, $ifNoneMatch );
+                       $return304 = in_array( $test, $match, true );
+               } else {
+                       $value = trim( $this->getRequest()->getHeader( 'If-Modified-Since' ) );
+
+                       // Some old browsers sends sizes after the date, like this:
+                       //  Wed, 20 Aug 2003 06:51:19 GMT; length=5202
+                       // Ignore that.
+                       $i = strpos( $value, ';' );
+                       if ( $i !== false ) {
+                               $value = trim( substr( $value, 0, $i ) );
+                       }
+
+                       if ( $value !== '' ) {
+                               try {
+                                       $ts = new MWTimestamp( $value );
+                                       if (
+                                               // RFC 7231 IMF-fixdate
+                                               $ts->getTimestamp( TS_RFC2822 ) === $value ||
+                                               // RFC 850
+                                               $ts->format( 'l, d-M-y H:i:s' ) . ' GMT' === $value ||
+                                               // asctime (with and without space-padded day)
+                                               $ts->format( 'D M j H:i:s Y' ) === $value ||
+                                               $ts->format( 'D M  j H:i:s Y' ) === $value
+                                       ) {
+                                               $lastMod = $module->getConditionalRequestData( 'last-modified' );
+                                               if ( $lastMod !== null ) {
+                                                       // Mix in some MediaWiki modification times
+                                                       $modifiedTimes = array(
+                                                               'page' => $lastMod,
+                                                               'user' => $this->getUser()->getTouched(),
+                                                               'epoch' => $this->getConfig()->get( 'CacheEpoch' ),
+                                                       );
+                                                       if ( $this->getConfig()->get( 'UseSquid' ) ) {
+                                                               // T46570: the core page itself may not change, but resources might
+                                                               $modifiedTimes['sepoch'] = wfTimestamp(
+                                                                       TS_MW, time() - $this->getConfig()->get( 'SquidMaxage' )
+                                                               );
+                                                       }
+                                                       Hooks::run( 'OutputPageCheckLastModified', array( &$modifiedTimes ) );
+                                                       $lastMod = max( $modifiedTimes );
+                                                       $return304 = wfTimestamp( TS_MW, $lastMod ) <= $ts->getTimestamp( TS_MW );
+                                               }
+                                       }
+                               } catch ( TimestampException $e ) {
+                                       // Invalid timestamp, ignore it
+                               }
+                       }
+               }
+
+               if ( $return304 ) {
+                       $this->getRequest()->response()->statusHeader( 304 );
+
+                       // Avoid outputting the compressed representation of a zero-length body
+                       MediaWiki\suppressWarnings();
+                       ini_set( 'zlib.output_compression', 0 );
+                       MediaWiki\restoreWarnings();
+                       wfClearOutputBuffers();
+
+                       return false;
+               }
+
+               return true;
+       }
+
        /**
         * Check for sufficient permissions to execute
         * @param ApiBase $module An Api module
@@ -1083,6 +1223,10 @@ class ApiMain extends ApiBase {
                        return;
                }
 
+               if ( !$this->checkConditionalRequestHeaders( $module ) ) {
+                       return;
+               }
+
                if ( !$this->mInternalMode ) {
                        $this->setupExternalResponse( $module, $params );
                }
index 4e4d2af..172ee99 100644 (file)
@@ -55,7 +55,6 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase {
 
                $result = $this->getResult();
                $pageSet = $this->getPageSet();
-               $titles = $pageSet->getTitles();
 
                // This module operates in two modes:
                // 'user': List deleted revs by a certain user
@@ -83,6 +82,21 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase {
                        }
                }
 
+               // If we're generating titles only, we can use DISTINCT for a better
+               // query. But we can't do that in 'user' mode (wrong index), and we can
+               // only do it when sorting ASC (because MySQL apparently can't use an
+               // index backwards for grouping even though it can for ORDER BY, WTF?)
+               $dir = $params['dir'];
+               $optimizeGenerateTitles = false;
+               if ( $mode === 'all' && $params['generatetitles'] && $resultPageSet !== null ) {
+                       if ( $dir === 'newer' ) {
+                               $optimizeGenerateTitles = true;
+                       } else {
+                               $p = $this->getModulePrefix();
+                               $this->setWarning( "For better performance when generating titles, set {$p}dir=newer" );
+                       }
+               }
+
                $this->addTables( 'archive' );
                if ( $resultPageSet === null ) {
                        $this->parseParameters( $params );
@@ -90,7 +104,12 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase {
                        $this->addFields( array( 'ar_title', 'ar_namespace' ) );
                } else {
                        $this->limit = $this->getParameter( 'limit' ) ?: 10;
-                       $this->addFields( array( 'ar_title', 'ar_namespace', 'ar_timestamp', 'ar_rev_id', 'ar_id' ) );
+                       $this->addFields( array( 'ar_title', 'ar_namespace' ) );
+                       if ( $optimizeGenerateTitles ) {
+                               $this->addOption( 'DISTINCT' );
+                       } else {
+                               $this->addFields( array( 'ar_timestamp', 'ar_rev_id', 'ar_id' ) );
+                       }
                }
 
                if ( $this->fld_tags ) {
@@ -130,7 +149,6 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase {
                        }
                }
 
-               $dir = $params['dir'];
                $miser_ns = null;
 
                if ( $mode == 'all' ) {
@@ -229,7 +247,14 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase {
                if ( !is_null( $params['continue'] ) ) {
                        $cont = explode( '|', $params['continue'] );
                        $op = ( $dir == 'newer' ? '>' : '<' );
-                       if ( $mode == 'all' ) {
+                       if ( $optimizeGenerateTitles ) {
+                               $this->dieContinueUsageIf( count( $cont ) != 2 );
+                               $ns = intval( $cont[0] );
+                               $this->dieContinueUsageIf( strval( $ns ) !== $cont[0] );
+                               $title = $db->addQuotes( $cont[1] );
+                               $this->addWhere( "ar_namespace $op $ns OR " .
+                                       "(ar_namespace = $ns AND ar_title $op= $title)" );
+                       } elseif ( $mode == 'all' ) {
                                $this->dieContinueUsageIf( count( $cont ) != 4 );
                                $ns = intval( $cont[0] );
                                $this->dieContinueUsageIf( strval( $ns ) !== $cont[0] );
@@ -259,7 +284,13 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase {
 
                $sort = ( $dir == 'newer' ? '' : ' DESC' );
                $orderby = array();
-               if ( $mode == 'all' ) {
+               if ( $optimizeGenerateTitles ) {
+                       // Targeting index name_title_timestamp
+                       if ( $params['namespace'] === null || count( array_unique( $params['namespace'] ) ) > 1 ) {
+                               $orderby[] = "ar_namespace $sort";
+                       }
+                       $orderby[] = "ar_title $sort";
+               } elseif ( $mode == 'all' ) {
                        // Targeting index name_title_timestamp
                        if ( $params['namespace'] === null || count( array_unique( $params['namespace'] ) ) > 1 ) {
                                $orderby[] = "ar_namespace $sort";
@@ -283,7 +314,9 @@ class ApiQueryAllDeletedRevisions extends ApiQueryRevisionsBase {
                foreach ( $res as $row ) {
                        if ( ++$count > $this->limit ) {
                                // We've had enough
-                               if ( $mode == 'all' ) {
+                               if ( $optimizeGenerateTitles ) {
+                                       $this->setContinueEnumParameter( 'continue', "$row->ar_namespace|$row->ar_title" );
+                               } elseif ( $mode == 'all' ) {
                                        $this->setContinueEnumParameter( 'continue',
                                                "$row->ar_namespace|$row->ar_title|$row->ar_timestamp|$row->ar_id"
                                        );
index a2c2844..8e7031c 100644 (file)
@@ -31,8 +31,6 @@
  * @ingroup API
  */
 class ApiQueryRandom extends ApiQueryGeneratorBase {
-       private $pageIDs;
-
        public function __construct( ApiQuery $query, $moduleName ) {
                parent::__construct( $query, $moduleName, 'rn' );
        }
@@ -46,102 +44,131 @@ class ApiQueryRandom extends ApiQueryGeneratorBase {
        }
 
        /**
-        * @param string $randstr
-        * @param int $limit
-        * @param int $namespace
-        * @param ApiPageSet $resultPageSet
-        * @param bool $redirect
-        * @return void
+        * Actually perform the query and add pages to the result.
+        * @param ApiPageSet|null $resultPageSet
+        * @param int $limit Number of pages to fetch
+        * @param string|null $start Starting page_random
+        * @param int|null $startId Starting page_id
+        * @param string|null $end Ending page_random
+        * @return array (int, string|null) Number of pages left to query and continuation string
         */
-       protected function prepareQuery( $randstr, $limit, $namespace, &$resultPageSet, $redirect ) {
+       protected function runQuery( $resultPageSet, $limit, $start, $startId, $end ) {
+               $params = $this->extractRequestParams();
+
                $this->resetQueryParams();
                $this->addTables( 'page' );
-               $this->addOption( 'LIMIT', $limit );
-               $this->addWhereFld( 'page_namespace', $namespace );
-               $this->addWhereRange( 'page_random', 'newer', $randstr, null );
-               $this->addWhereFld( 'page_is_redirect', $redirect );
+               $this->addFields( array( 'page_id', 'page_random' ) );
                if ( is_null( $resultPageSet ) ) {
-                       $this->addFields( array( 'page_id', 'page_title', 'page_namespace' ) );
+                       $this->addFields( array( 'page_title', 'page_namespace' ) );
                } else {
                        $this->addFields( $resultPageSet->getPageTableFields() );
                }
-       }
+               $this->addWhereFld( 'page_namespace', $params['namespace'] );
+               if ( $params['redirect'] || $params['filterredir'] === 'redirects' ) {
+                       $this->addWhereFld( 'page_is_redirect', 1 );
+               } elseif ( $params['filterredir'] === 'nonredirects' ) {
+                       $this->addWhereFld( 'page_is_redirect', 0 );
+               } elseif ( is_null( $resultPageSet ) ) {
+                       $this->addFields( array( 'page_is_redirect' ) );
+               }
+               $this->addOption( 'LIMIT', $limit + 1 );
+
+               if ( $start !== null ) {
+                       $start = $this->getDB()->addQuotes( $start );
+                       if ( $startId !== null ) {
+                               $startId = (int)$startId;
+                               $this->addWhere( "page_random = $start AND page_id >= $startId OR page_random > $start" );
+                       } else {
+                               $this->addWhere( "page_random >= $start" );
+                       }
+               }
+               if ( $end !== null ) {
+                       $this->addWhere( 'page_random < ' . $this->getDB()->addQuotes( $end ) );
+               }
+               $this->addOption( 'ORDER BY', array( 'page_random', 'page_id' ) );
+
+               $result = $this->getResult();
+               $path = array( 'query', $this->getModuleName() );
 
-       /**
-        * @param ApiPageSet $resultPageSet
-        * @return int
-        */
-       protected function runQuery( $resultPageSet = null ) {
                $res = $this->select( __METHOD__ );
                $count = 0;
                foreach ( $res as $row ) {
-                       $count++;
+                       if ( $count++ >= $limit ) {
+                               return array( 0, "{$row->page_random}|{$row->page_id}" );
+                       }
                        if ( is_null( $resultPageSet ) ) {
-                               // Prevent duplicates
-                               if ( !in_array( $row->page_id, $this->pageIDs ) ) {
-                                       $fit = $this->getResult()->addValue(
-                                               array( 'query', $this->getModuleName() ),
-                                               null, $this->extractRowInfo( $row ) );
-                                       if ( !$fit ) {
-                                               // We can't really query-continue a random list.
-                                               // Return an insanely high value so
-                                               // $count < $limit is false
-                                               return 1E9;
-                                       }
-                                       $this->pageIDs[] = $row->page_id;
+                               $title = Title::makeTitle( $row->page_namespace, $row->page_title );
+                               $page = array(
+                                       'id' => (int)$row->page_id,
+                               );
+                               ApiQueryBase::addTitleInfo( $page, $title );
+                               if ( isset( $row->page_is_redirect ) ) {
+                                       $page['redirect'] = (bool)$row->page_is_redirect;
+                               }
+                               $fit = $result->addValue( $path, null, $page );
+                               if ( !$fit ) {
+                                       return array( 0, "{$row->page_random}|{$row->page_id}" );
                                }
                        } else {
                                $resultPageSet->processDbRow( $row );
                        }
                }
 
-               return $count;
+               return array( $limit - $count, null );
        }
 
        /**
-        * @param ApiPageSet $resultPageSet
-        * @return void
+        * @param ApiPageSet|null $resultPageSet
         */
        public function run( $resultPageSet = null ) {
                $params = $this->extractRequestParams();
-               $result = $this->getResult();
-               $this->pageIDs = array();
-
-               $this->prepareQuery(
-                       wfRandom(),
-                       $params['limit'],
-                       $params['namespace'],
-                       $resultPageSet,
-                       $params['redirect']
-               );
-               $count = $this->runQuery( $resultPageSet );
-               if ( $count < $params['limit'] ) {
-                       /* We got too few pages, we probably picked a high value
-                        * for page_random. We'll just take the lowest ones, see
-                        * also the comment in Title::getRandomTitle()
-                        */
-                       $this->prepareQuery(
-                               0,
-                               $params['limit'] - $count,
-                               $params['namespace'],
-                               $resultPageSet,
-                               $params['redirect']
-                       );
-                       $this->runQuery( $resultPageSet );
+
+               // Since 'filterredir" will always be set in $params, we have to dig
+               // into the WebRequest to see if it was actually passed.
+               $request = $this->getMain()->getRequest();
+               if ( $request->getCheck( $this->encodeParamName( 'filterredir' ) ) ) {
+                       $this->requireMaxOneParameter( $params, 'filterredir', 'redirect' );
                }
 
-               if ( is_null( $resultPageSet ) ) {
-                       $result->addIndexedTagName( array( 'query', $this->getModuleName() ), 'page' );
+               if ( $params['redirect'] ) {
+                       $this->logFeatureUsage( "list=random&rnredirect=" );
+               }
+
+               if ( isset( $params['continue'] ) ) {
+                       $cont = explode( '|', $params['continue'] );
+                       $this->dieContinueUsageIf( count( $cont ) != 4 );
+                       $rand = $cont[0];
+                       $start = $cont[1];
+                       $startId = (int)$cont[2];
+                       $end = $cont[3] ? $rand : null;
+                       $this->dieContinueUsageIf( !preg_match( '/^0\.\d+$/', $rand ) );
+                       $this->dieContinueUsageIf( !preg_match( '/^0\.\d+$/', $start ) );
+                       $this->dieContinueUsageIf( $cont[2] !== (string)$startId );
+                       $this->dieContinueUsageIf( $cont[3] !== '0' && $cont[3] !== '1' );
+               } else {
+                       $rand = wfRandom();
+                       $start = $rand;
+                       $startId = null;
+                       $end = null;
                }
-       }
 
-       private function extractRowInfo( $row ) {
-               $title = Title::makeTitle( $row->page_namespace, $row->page_title );
-               $vals = array();
-               $vals['id'] = intval( $row->page_id );
-               ApiQueryBase::addTitleInfo( $vals, $title );
+               list( $left, $continue ) = $this->runQuery( $resultPageSet, $params['limit'], $start, $startId, $end );
+               if ( $end === null && $continue === null ) {
+                       // Wrap around. We do this even if $left === 0 for continuation
+                       // (saving a DB query in this rare case probably isn't worth the
+                       // added code complexity it would require).
+                       $end = $rand;
+                       list( $left, $continue ) = $this->runQuery( $resultPageSet, $left, null, null, $end );
+               }
+
+               if ( $continue !== null ) {
+                       $endFlag = $end === null ? 0 : 1;
+                       $this->setContinueEnumParameter( 'continue', "$rand|$continue|$endFlag" );
+               }
 
-               return $vals;
+               if ( is_null( $resultPageSet ) ) {
+                       $this->getResult()->addIndexedTagName( array( 'query', $this->getModuleName() ), 'page' );
+               }
        }
 
        public function getCacheMode( $params ) {
@@ -154,14 +181,24 @@ class ApiQueryRandom extends ApiQueryGeneratorBase {
                                ApiBase::PARAM_TYPE => 'namespace',
                                ApiBase::PARAM_ISMULTI => true
                        ),
+                       'filterredir' => array(
+                               ApiBase::PARAM_TYPE => array( 'all', 'redirects', 'nonredirects' ),
+                               ApiBase::PARAM_DFLT => 'nonredirects', // for BC
+                       ),
+                       'redirect' => array(
+                               ApiBase::PARAM_DEPRECATED => true,
+                               ApiBase::PARAM_DFLT => false,
+                       ),
                        'limit' => array(
                                ApiBase::PARAM_TYPE => 'limit',
                                ApiBase::PARAM_DFLT => 1,
                                ApiBase::PARAM_MIN => 1,
-                               ApiBase::PARAM_MAX => 10,
-                               ApiBase::PARAM_MAX2 => 20
+                               ApiBase::PARAM_MAX => ApiBase::LIMIT_BIG1,
+                               ApiBase::PARAM_MAX2 => ApiBase::LIMIT_BIG2
+                       ),
+                       'continue' => array(
+                               ApiBase::PARAM_HELP_MSG => 'api-help-param-continue'
                        ),
-                       'redirect' => false,
                );
        }
 
index 75a0adb..251c42b 100644 (file)
@@ -78,7 +78,6 @@ class ApiQueryUserInfo extends ApiQueryBase {
 
        protected function getCurrentUserInfo() {
                $user = $this->getUser();
-               $result = $this->getResult();
                $vals = array();
                $vals['id'] = intval( $user->getId() );
                $vals['name'] = $user->getName();
index 014ca85..142a780 100644 (file)
@@ -288,7 +288,7 @@ class ApiResult implements ApiSerializable {
         * @param int $flags Zero or more OR-ed flags like OVERRIDE | ADD_ON_TOP.
         */
        public static function setValue( array &$arr, $name, $value, $flags = 0 ) {
-               if ( !( $flags & ApiResult::NO_VALIDATE ) ) {
+               if ( ( $flags & ApiResult::NO_VALIDATE ) !== ApiResult::NO_VALIDATE ) {
                        $value = self::validateValue( $value );
                }
 
@@ -402,6 +402,11 @@ class ApiResult implements ApiSerializable {
                $arr = &$this->path( $path, ( $flags & ApiResult::ADD_ON_TOP ) ? 'prepend' : 'append' );
 
                if ( $this->checkingSize && !( $flags & ApiResult::NO_SIZE_CHECK ) ) {
+                       // self::valueSize needs the validated value. Then flag
+                       // to not re-validate later.
+                       $value = self::validateValue( $value );
+                       $flags |= ApiResult::NO_VALIDATE;
+
                        $newsize = $this->size + self::valueSize( $value );
                        if ( $this->maxSize !== false && $newsize > $this->maxSize ) {
                                /// @todo Add i18n message when replacing calls to ->setWarning()
@@ -1079,14 +1084,12 @@ class ApiResult implements ApiSerializable {
         * or the sum of the strlen()s of the elements if the item is an array.
         * @note Once the deprecated public self::size is removed, we can rename
         *       this back to a less awkward name.
-        * @param mixed $value
+        * @param mixed $value Validated value (see self::validateValue())
         * @return int
         */
        private static function valueSize( $value ) {
                $s = 0;
-               if ( is_array( $value ) ||
-                       is_object( $value ) && !is_callable( array( $value, '__toString' ) )
-               ) {
+               if ( is_array( $value ) ) {
                        foreach ( $value as $k => $v ) {
                                if ( !self::isMetadataKey( $s ) ) {
                                        $s += self::valueSize( $v );
@@ -1274,7 +1277,7 @@ class ApiResult implements ApiSerializable {
         */
        public static function setElement( &$arr, $name, $value, $flags = 0 ) {
                wfDeprecated( __METHOD__, '1.25' );
-               return self::setValue( $arr, $name, $value, $flags );
+               self::setValue( $arr, $name, $value, $flags );
        }
 
        /**
@@ -1488,7 +1491,7 @@ class ApiResult implements ApiSerializable {
         */
        public static function size( $value ) {
                wfDeprecated( __METHOD__, '1.25' );
-               return self::valueSize( $value );
+               return self::valueSize( self::validateValue( $value ) );
        }
 
        /**
index aa456f0..7bdf29a 100644 (file)
@@ -4,7 +4,8 @@
                        "Meno25",
                        "أحمد المحمودي",
                        "Khaled",
-                       "Fatz"
+                       "Fatz",
+                       "Hiba Alshawi"
                ]
        },
        "apihelp-main-param-format": "صيغة الخرج.",
@@ -24,5 +25,6 @@
        "apihelp-edit-param-watch": "أضف الصفحة إلى لائحة مراقبة المستعمل الحالي",
        "apihelp-emailuser-description": "مراسلة المستخدم",
        "apihelp-patrol-example-rcid": "ابحث عن تغيير جديد",
+       "apihelp-query+imageinfo-paramvalue-prop-userid": "إضافة هوية المستخدم الذي قام بتحميل كل إصدار ملف.",
        "apihelp-query+prefixsearch-param-offset": "عدد النتائج المراد تخطيها."
 }
index 0b6c167..7c4ddcb 100644 (file)
        "api-help-param-deprecated": "Veraltet.",
        "api-help-param-required": "Dieser Parameter ist erforderlich.",
        "api-help-datatypes-header": "Datentypen",
-       "api-help-param-list": "{{PLURAL:$1|1=Ein Wert|2=Werte (mit <kbd>{{!}}</kbd> trennen)}}: $2",
+       "api-help-param-list": "{{PLURAL:$1|1=Einer der folgenden Werte|2=Werte (mit <kbd>{{!}}</kbd> trennen)}}: $2",
        "api-help-param-list-can-be-empty": "{{PLURAL:$1|0=Muss leer sein|Kann leer sein oder $2}}",
        "api-help-param-limit": "Nicht mehr als $1 erlaubt.",
        "api-help-param-limit2": "Nicht mehr als $1 ($2 für Bots) erlaubt.",
index 39d44d2..2cb0e37 100644 (file)
        "apihelp-query+querypage-param-limit": "Number of results to return.",
        "apihelp-query+querypage-example-ancientpages": "Return results from [[Special:Ancientpages]].",
 
-       "apihelp-query+random-description": "Get a set of random pages.\n\nPages are listed in a fixed sequence, only the starting point is random. This means that if, for example, <samp>Main Page</samp> is the first random page in the list, <samp>List of fictional monkeys</samp> will <em>always</em> be second, <samp>List of people on stamps of Vanuatu</samp> third, etc.\n\nIf the number of pages in the namespace is lower than <var>$1limit</var>, fewer pages will be returned. The same page will not be returned twice.",
+       "apihelp-query+random-description": "Get a set of random pages.\n\nPages are listed in a fixed sequence, only the starting point is random. This means that if, for example, <samp>Main Page</samp> is the first random page in the list, <samp>List of fictional monkeys</samp> will <em>always</em> be second, <samp>List of people on stamps of Vanuatu</samp> third, etc.",
        "apihelp-query+random-param-namespace": "Return pages in these namespaces only.",
        "apihelp-query+random-param-limit": "Limit how many random pages will be returned.",
-       "apihelp-query+random-param-redirect": "Load a random redirect instead of a random page.",
+       "apihelp-query+random-param-redirect": "Use <kbd>$1filterredir=redirects</kbd> instead.",
+       "apihelp-query+random-param-filterredir": "How to filter for redirects.",
        "apihelp-query+random-example-simple": "Return two random pages from the main namespace.",
        "apihelp-query+random-example-generator": "Return page info about two random pages from the main namespace.",
 
        "api-help-param-type-password": "",
        "api-help-param-type-timestamp": "Type: {{PLURAL:$1|1=timestamp|2=list of timestamps}} ([[Special:ApiHelp/main#main/datatypes|allowed formats]])",
        "api-help-param-type-user": "Type: {{PLURAL:$1|1=user name|2=list of user names}}",
-       "api-help-param-list": "{{PLURAL:$1|1=One value|2=Values (separate with <kbd>{{!}}</kbd>)}}: $2",
+       "api-help-param-list": "{{PLURAL:$1|1=One of the following values|2=Values (separate with <kbd>{{!}}</kbd>)}}: $2",
        "api-help-param-list-can-be-empty": "{{PLURAL:$1|0=Must be empty|Can be empty, or $2}}",
        "api-help-param-limit": "No more than $1 allowed.",
        "api-help-param-limit2": "No more than $1 ($2 for bots) allowed.",
index 0657fd7..6b6345d 100644 (file)
        "apihelp-query+logevents-paramvalue-prop-details": "Lista detalles adicionais do evento.",
        "apihelp-query+logevents-paramvalue-prop-tags": "Lista as etiquetas do evento.",
        "apihelp-query+logevents-param-type": "Filtrar as entradas do rexistro para mostrar só as deste tipo.",
-       "apihelp-query+logevents-param-action": "Filtrar accións no rexistro para mostrar só esta acción. Ignora <var>$1type</var>. Accións comodín como  <kbd>action/*</kbd> permiten especificar calquera cadea para o asterisco.",
+       "apihelp-query+logevents-param-action": "Filtrar accións no rexistro para mostrar só esta acción. Ignora <var>$1type</var>. Na lista de posibles valores, valores coa máscara asterisco como <kbd>action/*</kbd> poden ter diferentes cadeas despois da barra (/).",
        "apihelp-query+logevents-param-start": "Selo de tempo no que comezar a enumeración.",
        "apihelp-query+logevents-param-end": "Selo de tempo para rematar a enumeración.",
        "apihelp-query+logevents-param-user": "Filtrar entradas ás feitas polo usuario indicado.",
        "apihelp-query+querypage-param-page": "Nome da páxina especial. Teña en conta que diferencia entre maiúsculas e minúsculas.",
        "apihelp-query+querypage-param-limit": "Número de resultados a visualizar.",
        "apihelp-query+querypage-example-ancientpages": "Resultados devoltos de [[Special:Ancientpages]].",
-       "apihelp-query+random-description": "Obter un conxunto de páxinas aleatorias.\n\nAs páxinas están listadas nunha secuencia fixa, só o punto de comezo é aleatorio. Isto significa que se, por exemplo, a <samp>Main Page</samp> é a primeira páxina aleatoria da lista, a <samp>Lista de monos ficticios</samp> será <em>sempre</em> a segunda, <samp>Lista de xente en selos de Vanuatu</samp> será a terceira, etc.\n\nSe o númeor de páxinas do espazo de nomes é menor que <var>$1limit</var>, devolveranse menos páxinas. Non se devolverá dúas veces a mesma páxina.",
+       "apihelp-query+random-description": "Obter un conxunto de páxinas aleatorias.\n\nAs páxinas están listadas nunha secuencia fixa, só o punto de comezo é aleatorio. Isto significa que se, por exemplo, a <samp>Main Page</samp> é a primeira páxina aleatoria da lista, a <samp>Lista de monos ficticios</samp> será <em>sempre</em> a segunda, <samp>Lista de xente en selos de Vanuatu</samp> será a terceira, etc.",
        "apihelp-query+random-param-namespace": "Devolver páxinas só neste espazo de nomes.",
        "apihelp-query+random-param-limit": "Limitar cantas páxinas aleatorias se van devolver.",
-       "apihelp-query+random-param-redirect": "Cargar unha redirección aleatoria no canto dunha páxina aleatoria.",
+       "apihelp-query+random-param-redirect": "No canto use <kbd>$1filterredir=redirects</kbd>.",
+       "apihelp-query+random-param-filterredir": "Como filtrar para redireccións.",
        "apihelp-query+random-example-simple": "Obter dúas páxinas aleatorias do espazo de nomes principal.",
        "apihelp-query+random-example-generator": "Obter a información da páxina de dúas páxinas aleatorias do espazo de nomes principal.",
        "apihelp-query+recentchanges-description": "Enumerar cambios recentes.",
        "api-help-param-type-boolean": "Tipo: booleano ([[Special:ApiHelp/main#main/datatypes|detalles]])",
        "api-help-param-type-timestamp": "Tipo: {{PLURAL:$1|1=selo de tempo|2=lista de selos de tempo}} ([[Special:ApiHelp/main#main/datatypes|formatos permitidos]])",
        "api-help-param-type-user": "Tipo: {{PLURAL:$1|1=nome de usuario|2=lista de nomes de usuarios}}",
-       "api-help-param-list": "{{PLURAL:$1|1=Un valor|2=Valores (separados con <kbd>{{!}}</kbd>)}}: $2",
+       "api-help-param-list": "{{PLURAL:$1|1=Un valor dos seguintes valores|2=Valores (separados con <kbd>{{!}}</kbd>)}}: $2",
        "api-help-param-list-can-be-empty": "{{PLURAL:$1|0=Debe ser baleiro|Pode ser baleiro, ou $2}}",
        "api-help-param-limit": "Non se permiten máis de $1.",
        "api-help-param-limit2": "Non se permiten máis de $1 ($2 para bots).",
index de8e83d..54815f8 100644 (file)
        "apihelp-query+logevents-paramvalue-prop-details": "הוספת פרטים נוספים על האירוע.",
        "apihelp-query+logevents-paramvalue-prop-tags": "רשימת התגים של האירוע.",
        "apihelp-query+logevents-param-type": "סינון עיולי יומן רק לסוג הזה.",
-       "apihelp-query+logevents-param-action": "ס×\99× ×\95×\9f ×¤×¢×\95×\9c×\95ת ×\99×\95×\9e×\9f ×¨×§ ×\9cפע×\95×\9c×\94 ×\94×\96×\90ת. ×\93×\95רס ×\90ת <var>$1type</var>. ×¤×¢×\95×\9c×\95ת ×¢×\9d ×ª×\95Ö¾×\9b×\95×\9c×\99×\9d ×\9b×\92×\95×\9f <kbd>action/*</kbd> ×\9e×\90פשר×\95ת ×\9cתת ×\9b×\9c ×\9e×\97ר×\95×\96ת ×\91×\9e×§×\95×\9d ×\94×\9b×\95×\9b×\91×\99ת.",
+       "apihelp-query+logevents-param-action": "ס×\99× ×\95×\9f ×¤×¢×\95×\9c×\95ת ×\99×\95×\9e×\9f ×¨×§ ×\9cפע×\95×\9c×\94 ×\94×\96×\90ת. ×\93×\95רס ×\90ת <var>$1type</var>. ×\91רש×\99×\9eת ×\94ער×\9b×\99×\9d ×\94×\90פשר×\99×\99×\9d, ×¢×¨×\9b×\99×\9d ×¢×\9d ×ª×\95Ö¾×\9b×\9c ×\9b×\95×\9b×\91×\99ת ×\9b×\92×\95×\9f <kbd>action/*</kbd> ×\99×\9b×\95×\9c×\99×\9d ×\9c×\94×\99×\95ת ×\9e×\97ר×\95×\96×\95ת ×©×\95× ×\95ת ×\90×\97ר×\99 ×\94×§×\95 ×\94× ×\98×\95×\99 (/).",
        "apihelp-query+logevents-param-start": "מאיזה חותם־זמן להתחיל למנות.",
        "apihelp-query+logevents-param-end": "באיזה חותם זמן להפסיק לרשום.",
        "apihelp-query+logevents-param-user": "לסנן את העיולים שעשה המשתמש הנתון.",
        "apihelp-query+querypage-param-page": "שם הדף המיוחד. לתשומת לבך, זה תלוי־רישיות.",
        "apihelp-query+querypage-param-limit": "מספר תוצאות להחזרה.",
        "apihelp-query+querypage-example-ancientpages": "מחזיר תוצאות מ־[[Special:Ancientpages]].",
-       "apihelp-query+random-description": "קבלת ערכת דפים אקראיים.\n\nהדפים רשומים בסדר קבוע, ורק נקודת ההתחלה אקראית. זה אומר שאם, למשל, <samp>Main Page</samp> הוא הדף האקראי הראשון הרשימה, <samp>List of fictional monkeys</samp> יהיה <em>תמיד</em> השני, <samp>List of people on stamps of Vanuatu</samp> שלישי, וכו'.\n\nאם מספר הדפים במרחב השם נמוך מ־<var>$1limit</var>, יוחזרו פחות דפים. אותו הדף לא יוחזר פעמיים.",
+       "apihelp-query+random-description": "קבלת ערכת דפים אקראיים.\n\nהדפים רשומים בסדר קבוע, ורק נקודת ההתחלה אקראית. זה אומר שאם, למשל, <samp>Main Page</samp> הוא הדף האקראי הראשון הרשימה, <samp>List of fictional monkeys</samp> יהיה <em>תמיד</em> השני, <samp>List of people on stamps of Vanuatu</samp> שלישי, וכו'.",
        "apihelp-query+random-param-namespace": "מחזיר דפים רק במרחבי השם האלה.",
        "apihelp-query+random-param-limit": "להגביל את מספר הדפים האקראיים שיוחזרו.",
-       "apihelp-query+random-param-redirect": "לטעון הניה אקראית במקום דף אקראי.",
+       "apihelp-query+random-param-redirect": "נא להשתמש ב־<kbd>$1filterredir=redirects</kbd> במקום.",
+       "apihelp-query+random-param-filterredir": "איך לסנן הפניות.",
        "apihelp-query+random-example-simple": "להחזיר שני דפים אקראיים מהמרחב הראשי.",
        "apihelp-query+random-example-generator": "החזרת מידע על הדף על שני דפים אקראיים מהמרחב הראשי.",
        "apihelp-query+recentchanges-description": "למנות שינויים אחרונים.",
        "apihelp-query+search-paramvalue-prop-sectiontitle": "הוספת שם הפסקה התואמת.",
        "apihelp-query+search-paramvalue-prop-categorysnippet": "הוספת קטע קצר מפוענח של הקטגוריה התואמת.",
        "apihelp-query+search-paramvalue-prop-isfilematch": "הוספת בוליאני שמציין אם החיפוש תאם לתוכן של קובץ.",
-       "apihelp-query+search-paramvalue-prop-score": "<span class=\"apihelp-deprecated\">×\9e×\99×\95ש×\9f ×\95×\97סר־ת×\95×§×\9f.</span>",
-       "apihelp-query+search-paramvalue-prop-hasrelated": "<span class=\"apihelp-deprecated\">×\9e×\99×\95ש×\9f ×\95×\97סר־ת×\95×§×\9f.</span>",
+       "apihelp-query+search-paramvalue-prop-score": "<span class=\"apihelp-deprecated\">×\9e×\99×\95ש×\9f ×\95×\97סר־×\94שפע×\94.</span>",
+       "apihelp-query+search-paramvalue-prop-hasrelated": "<span class=\"apihelp-deprecated\">×\9e×\99×\95ש×\9f ×\95×\97סר־×\94שפע×\94.</span>",
        "apihelp-query+search-param-limit": "כמה דפים להחזיר בסך הכול.",
-       "apihelp-query+search-param-interwiki": "לכלול תוצאות בינוויקי בחיפוש ם זמין.",
+       "apihelp-query+search-param-interwiki": "לכלול תוצאות בינוויקי בחיפוש, אם זמין.",
        "apihelp-query+search-param-backend": "באיזה שרת חיפוש להשתמש אם לא בבררת המחדל.",
        "apihelp-query+search-example-simple": "חיפוש <kbd>meaning</kbd>.",
        "apihelp-query+search-example-text": "חיפוש טקסטים עבור <kbd>meaning</kbd>.",
        "api-help-param-type-boolean": "סוג: בוליאני ([[Special:ApiHelp/main#main/datatypes|פרטים]])",
        "api-help-param-type-timestamp": "סוג: {{PLURAL:$1|חותם־זמן|רשימת חותמי־זמן}} ([[Special:ApiHelp/main#main/datatypes|תסדירים מורשים]])",
        "api-help-param-type-user": "סוג: {{PLURAL:$1|1=שם משתמש|2=רשימת שמות משתמשים}}",
-       "api-help-param-list": "{{PLURAL:$1|1=ער×\9a ×\90×\97×\93|2=ערכים (מופרדים באמצעות \"<kbd>{{!}}</kbd>\")}}: $2",
+       "api-help-param-list": "{{PLURAL:$1|1=×\90×\97×\93 ×\9e×\94ער×\9b×\99×\9d ×\94×\91×\90×\99×\9d|2=ערכים (מופרדים באמצעות \"<kbd>{{!}}</kbd>\")}}: $2",
        "api-help-param-list-can-be-empty": "{{PLURAL:$1|0=חייב להיות ריק|יכול להיות ריק או $2}}",
        "api-help-param-limit": "מספר הפרמטרים לא יכול להיות גדול מ־$1.",
        "api-help-param-limit2": "המספר המרבי המותר הוא $1 (עבור בוטים – $2).",
        "api-help-permissions-granted-to": "{{PLURAL:$1|הוענק ל|הוענקו ל}}: $2",
        "api-help-right-apihighlimits": "להשתמש במגבלות גבוהות יותר בשאילתות API (שאילתות אטיות: $1; שאילתות מהירות: $2). המגבלות לשאילתות אטיות חלות גם על פרמטרים מרובי־ערכים.",
        "api-credits-header": "קרדיטים",
-       "api-credits": "מפתחי ה־API:\n* רואן קטאו (מפתח מוביל 2007–2009)\n* ויקטור וסילייב\n* בריאן טונג מין\n* סאם ריד\n* יורי אסטרחן (יוצר, מפתח מוביל מספטמבר 2006 עד ספטמבר 2007)\n* בראד יורש (מפתח מוביל מאז 2013)\n\nאנא שלחו הערות, הצעות ושאלות לכתובת mediawiki-api@lists.wikimedia.org או כתבו דיווח באג באתר https://bugzilla.wikimedia.org."
+       "api-credits": "מפתחי ה־API:\n* רואן קטאו (מפתח מוביל 2007–2009)\n* ויקטור וסילייב\n* בריאן טונג מין\n* סאם ריד\n* יורי אסטרחן (יוצר, מפתח מוביל מספטמבר 2006 עד ספטמבר 2007)\n* בראד יורש (מפתח מוביל מאז 2013)\n\nאנא שלחו הערות, הצעות ושאלות לכתובת mediawiki-api@lists.wikimedia.org או כתבו דיווח באג באתר https://phabricator.wikimedia.org."
 }
index 8dac7e0..bb403c6 100644 (file)
        "api-help-parameters": "{{PLURAL:$1|パラメーター}}:",
        "api-help-param-deprecated": "廃止予定です。",
        "api-help-param-required": "このパラメーターは必須です。",
-       "api-help-param-list": "{{PLURAL:$1|1=値 (いずれか1つ)|2=値 (<kbd>{{!}}</kbd>で区切る)}}: $2",
+       "api-help-param-list": "{{PLURAL:$1|1=値 (次の値のいずれか1つ)|2=値 (<kbd>{{!}}</kbd>で区切る)}}: $2",
        "api-help-param-list-can-be-empty": "{{PLURAL:$1|0=空欄にしてください|空欄にするか、または $2}}",
        "api-help-param-integer-min": "{{PLURAL:$1|値}}は $2 以上にしてください。",
        "api-help-param-integer-max": "{{PLURAL:$1|値}}は $3 以下にしてください。",
index a263e09..46ef968 100644 (file)
        "apihelp-query+imageinfo-paramvalue-prop-userid": "Deiht de Kännong vun jehdem Metmaacher derbei, dä en Väsohn vun dä Dattei huh jelaahde hät.",
        "apihelp-query+imageinfo-paramvalue-prop-comment": "Aanmärkonge bei dä Väsjohn.",
        "apihelp-query+imageinfo-paramvalue-prop-parsedcomment": "Donn di Aanmärkonge bei dä Väsjohn paase.",
-       "apihelp-query+imageinfo-paramvalue-prop-canonicaltitle": "Deiht de kannohnesche Överschreff vun dä Dattei derbei.",
+       "apihelp-query+imageinfo-paramvalue-prop-canonicaltitle": "Deiht de kannohnesche, schtandattmähßejje, Överschreff vun dä Dattei derbei.",
        "apihelp-query+imageinfo-paramvalue-prop-url": "Jitt dä <i lang=\"en\" xml:lang=\"en\" dir=\"ltr\" title=\"Uniform Ressource Locator\">URL</i> för di Dattei un de Sigg met däh iere Äkliehrong uß.",
        "apihelp-query+imageinfo-paramvalue-prop-size": "Deiht de Jrühße vun dä Dattei en \n<i lang=\"en\" xml:lang=\"en\" dir=\"ltr\">Bytes</i>, de Hühde, de Breide, un, woh et se jitt, de Aanzahl Sigge derbei.",
        "apihelp-query+imageinfo-paramvalue-prop-dimensions": "Et sällve, wi de Jrühße.",
        "apihelp-query+querypage-example-ancientpages": "Donn de Äjehbneße vun „<code lang=\"en\" xml:lang=\"en\" dir=\"ltr\">[[Special:Ancientpages]]</code>“ ußjävve.",
        "apihelp-query+random-param-namespace": "Jiff blohß sigge en heh dä Appachtemangs uß.",
        "apihelp-query+random-param-limit": "Wi vill zohfälleje Sigge sulle ußjejovve wähde?",
-       "apihelp-query+random-param-redirect": "Donn en zohfälleje Ömleijdong anschtatt vun ene zohfälleje Sigg lahde.",
+       "apihelp-query+random-param-redirect": "Nemm <kbd>$1filterredir=redirects</kbd> schtatt dämm.",
        "apihelp-query+random-example-simple": "Donn zwai zohfälleje Sigge vum Houb_Appachtemang ußjävve.",
        "apihelp-query+random-example-generator": "Donn Ennfommazjuhne övver zwai zohfälleje Sigge vum Houb_Appachtemang ußjävve.",
        "apihelp-query+recentchanges-description": "Donn de  neußte Änderonge opleßte.",
        "api-help-param-type-boolean": "Zoot: Boolsch ([[Special:ApiHelp/main#main/datatypes|Einjzelheijte]])",
        "api-help-param-type-timestamp": "Zoot: {{PLURAL:$1|1=en Dattomm un en Zigg|2=en Leß met Aanjahbe us Dattom un Zigg}} (de [[Special:ApiHelp/main#main/datatypes|zohjelohße Fommahte]])",
        "api-help-param-type-user": "Zoot: {{PLURAL:$1|1=ene Metmaacher_Nahme|2=en Leß met Metmaacher_Nahme}}",
-       "api-help-param-list": "{{PLURAL:$1|1=Eijne Wäät|2=Wääte met <kbd>{{!}}</kbd> derzwesche}}: $2",
+       "api-help-param-list": "{{PLURAL:$1|1=Eijne Wäät|2=Wääte met <kbd>{{!}}</kbd> derzwesche}} vun dänne heh: $2",
        "api-help-param-list-can-be-empty": "{{PLURAL:$1|0=Moß läddesch sin|Kann läddesch sin, udder $2}}",
        "api-help-param-limit": "Nit mih wi $1 sin zohjelohße.",
        "api-help-param-limit2": "Nit mih wi $1 sin zohjelohße, ävver $2 för de Bots.",
diff --git a/includes/api/i18n/mr.json b/includes/api/i18n/mr.json
new file mode 100644 (file)
index 0000000..30cf75b
--- /dev/null
@@ -0,0 +1,11 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Rahuldeshmukh101"
+               ]
+       },
+       "apihelp-main-param-action": "कोणति कारवाई करायचि",
+       "apihelp-main-param-curtimestamp": "निकालात आताच्या वेळेचि नोन्द घ्या",
+       "apihelp-block-description": "सदस्यास ब्यान करा",
+       "apihelp-block-param-user": "सदस्याचे नाव, अंक पत्त्ता अथवा अंकपत्यांनचि मालिका प्रतिबांधित करा"
+}
diff --git a/includes/api/i18n/olo.json b/includes/api/i18n/olo.json
new file mode 100644 (file)
index 0000000..99aef3f
--- /dev/null
@@ -0,0 +1,12 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Mashoi7"
+               ]
+       },
+       "apihelp-createaccount-param-name": "Käyttäitunnus.",
+       "apihelp-delete-description": "Ota sivu iäre.",
+       "apihelp-login-param-name": "Käyttäitunnus.",
+       "apihelp-login-param-password": "Peittosana.",
+       "apihelp-login-example-login": "Kirjuttai."
+}
index e6aab1e..d2ebb3a 100644 (file)
@@ -10,7 +10,8 @@
                        "Pio387",
                        "Peter Bowman",
                        "Darellur",
-                       "The Polish"
+                       "The Polish",
+                       "Matma Rex"
                ]
        },
        "apihelp-main-param-action": "Wybierz akcję do wykonania.",
        "api-help-param-type-boolean": "Typ: wartość logiczna ([[Special:ApiHelp/main#main/datatypes|szczegóły]])",
        "api-help-param-type-timestamp": "Typ: {{PLURAL:$1|1=znacznik czasu|2=lista znaczników czasu}} ([[Special:ApiHelp/main#main/datatypes|dozwolone formaty]])",
        "api-help-param-type-user": "Typ: {{PLURAL:$1|1=nazwa użytkownika|2=lista nazw uzytkowników}}",
-       "api-help-param-list": "{{PLURAL:$1|1=Jedna wartość|2=Wartości (oddziel za pomocą <kbd>{{!}}</kbd>)}}: $2",
+       "api-help-param-list": "{{PLURAL:$1|1=Jedna z następujących wartość|2=Wartości (oddziel za pomocą <kbd>{{!}}</kbd>)}}: $2",
        "api-help-param-limit": "Nie więcej niż $1 dozwolone.",
        "api-help-param-limit2": "Nie więcej niż $1 ($2 dla botów) dozwolone.",
-       "api-help-param-integer-min": "{{PLURAL:$1|1=Wartość|2=Wartości}} musza być mniejsze niż $2.",
-       "api-help-param-integer-max": "{{PLURAL:$1|1=Wartość musi|2=Wartości muszą}} być nie większa niż $3.",
+       "api-help-param-integer-min": "{{PLURAL:$1|1=Wartość musi być nie mniejsza|2=Wartości muszą być nie mniejsze}} niż $2.",
+       "api-help-param-integer-max": "{{PLURAL:$1|1=Wartość musi być nie większa|2=Wartości muszą być nie większe}} niż $3.",
        "api-help-param-integer-minmax": "{{PLURAL:$1|1=Wartość musi|2=Wartości muszą}} być pomiędzy $2 a $3.",
        "api-help-param-multi-separate": "Oddziel wartości za pomocą <kbd>|</kbd>.",
        "api-help-param-multi-max": "Maksymalna liczba wartości to {{PLURAL:$1|$1}} ({{PLURAL:$2|$2}} dla botów).",
index 49df26b..9d24281 100644 (file)
@@ -9,10 +9,19 @@
        "apihelp-block-param-reason": "د بنديز سبب.",
        "apihelp-createaccount-param-name": "کارن-نوم.",
        "apihelp-delete-description": "يو مخ ړنگول.",
+       "apihelp-edit-description": "مخونه جوړول او سمول.",
        "apihelp-edit-param-text": "مخ مېنځپانگه.",
+       "apihelp-edit-param-minor": "وړوکی سمون.",
        "apihelp-edit-example-edit": "يو مخ سمول.",
        "apihelp-emailuser-description": "کارن ته برېښليک لېږل.",
        "apihelp-expandtemplates-param-title": "د مخ سرليک.",
+       "apihelp-feedrecentchanges-param-hideminor": "وړوکي بدلونونه پټول.",
+       "apihelp-feedrecentchanges-param-hidebots": "د روباټونو لخوا ترسره شوي بدلونونه پټول.",
+       "apihelp-feedrecentchanges-param-hideanons": "د ورکنومو کارنانو لخوا ترسره شوي بدلونونه پټول.",
+       "apihelp-feedrecentchanges-param-hideliu": "د ثبت شويو کارنانو لخوا ترسره شوي بدلونونه پټول.",
+       "apihelp-feedrecentchanges-param-hidepatrolled": "څارل شوي بدلونونه پټول.",
+       "apihelp-feedrecentchanges-param-hidemyself": "د اوسني کارن لخوا ترسره شوي بدلونونه پټول.",
+       "apihelp-feedrecentchanges-param-tagfilter": "د نښلن له مخې چاڼول.",
        "apihelp-login-param-name": "کارن نوم.",
        "apihelp-login-param-password": "پټنوم.",
        "apihelp-login-param-domain": "شپول (اختياري).",
        "apihelp-move-description": "يو مخ لېږدول.",
        "apihelp-query+search-example-simple": "د <kbd>مانا</kbd> پلټل.",
        "apihelp-query+search-example-text": "د <kbd>مانا</kbd> لپاره متنونه پلټل.",
+       "apihelp-query+watchlist-paramvalue-prop-title": "د يو مخ سرليک ورگډوي.",
        "apihelp-tag-param-reason": "د بدلون سبب.",
+       "apihelp-unblock-param-reason": "د بنديز ليرې کولو سبب.",
        "apihelp-upload-param-watch": "مخ کتل.",
        "apihelp-upload-param-file": "د دوتنې مېنځپانگه.",
        "apihelp-userrights-param-user": "کارن نوم.",
        "apihelp-userrights-param-userid": "کارن پېژند.",
+       "apihelp-userrights-param-reason": "د بدلون سبب.",
        "api-help-source": "سرچينه: $1",
        "api-help-source-unknown": "سرچينه: <span class=\"apihelp-unknown\">ناجوت</span>",
        "api-help-license": "منښتليک: [[$1|$2]]",
index 150ad8e..aaa0fad 100644 (file)
@@ -96,6 +96,7 @@
        "api-help-param-deprecated": "Obsoleto.",
        "api-help-param-required": "Este parâmetro é obrigatório.",
        "api-help-datatypes-header": "Tipo de dados",
+       "api-help-param-list": "{{PLURAL:$1|1=Um dos seguintes valores|2=Valores (separar com <kbd>{{!}}</kbd>)}}: $2",
        "api-help-param-multi-separate": "Separe os valores com <kbd>|</kbd>.",
        "api-help-param-default": "Padrão: $1",
        "api-help-param-default-empty": "Padrão: <span class=\"apihelp-empty\">(vazio)</span>",
index cd8d135..f39f5d0 100644 (file)
        "apihelp-query+imageinfo-paramvalue-prop-userid": "Imageinfo returns information about file revisions (normally the last revision since <code>iilimit</code> defaults to 1). <code>userid</code> includes the ID of the user who made the (re)upload which created that revision. So there will be one user ID per imageinfo item; if you set the limit high enough, you will get all revisions of all files as separate imageinfo items.\n\n{{doc-apihelp-paramvalue|query+imageinfo|prop|userid}}",
        "apihelp-query+imageinfo-paramvalue-prop-comment": "{{doc-apihelp-paramvalue|query+imageinfo|prop|comment}}",
        "apihelp-query+imageinfo-paramvalue-prop-parsedcomment": "{{doc-apihelp-paramvalue|query+imageinfo|prop|parsedcomment}}",
-       "apihelp-query+imageinfo-paramvalue-prop-canonicaltitle": "{{doc-apihelp-paramvalue|query+imageinfo|prop|canonicaltitle}}",
+       "apihelp-query+imageinfo-paramvalue-prop-canonicaltitle": "A canonocal title is aa title formatted in the same way you would see it on the top of the page (localized namespace name, first letters capitalized, spaces instead of underscores). \n{{doc-apihelp-paramvalue|query+imageinfo|prop|canonicaltitle}}",
        "apihelp-query+imageinfo-paramvalue-prop-url": "{{doc-apihelp-paramvalue|query+imageinfo|prop|url}}",
        "apihelp-query+imageinfo-paramvalue-prop-size": "{{doc-apihelp-paramvalue|query+imageinfo|prop|size}}",
        "apihelp-query+imageinfo-paramvalue-prop-dimensions": "{{doc-apihelp-paramvalue|query+imageinfo|prop|dimensions}}",
        "apihelp-query+random-param-namespace": "{{doc-apihelp-param|query+random|namespace}}",
        "apihelp-query+random-param-limit": "{{doc-apihelp-param|query+random|limit}}",
        "apihelp-query+random-param-redirect": "{{doc-apihelp-param|query+random|redirect}}",
+       "apihelp-query+random-param-filterredir": "{{apihelp-param|query+random|filterredir}}",
        "apihelp-query+random-example-simple": "{{doc-apihelp-example|query+random}}",
        "apihelp-query+random-example-generator": "{{doc-apihelp-example|query+random}}",
        "apihelp-query+recentchanges-description": "{{doc-apihelp-description|query+recentchanges}}",
index 0b8804b..56b3f5b 100644 (file)
@@ -15,8 +15,8 @@
        "apihelp-main-description": "<div class=\"hlist plainlinks api-main-links\">\n* [[mw:API:Main_page|Документация]]\n* [[mw:API:FAQ|ЧаВО]]\n* [https://lists.wikimedia.org/mailman/listinfo/mediawiki-api Почтовая рассылка]\n* [https://lists.wikimedia.org/mailman/listinfo/mediawiki-api-announce Новости API]\n* [https://phabricator.wikimedia.org/maniphest/query/GebfyV4uCaLd/#R Ошибки и запросы]\n</div>\n<strong>Статус:</strong> Все отображаемые на этой странице функции должны работать, однако API находится в статусе активной разработки, и может измениться в любой момент. Подпишитесь на  [https://lists.wikimedia.org/pipermail/mediawiki-api-announce/ почтовую рассылку mediawiki-api-announce], чтобы быть в курсе обновлений.\n\n<strong>Ошибочные запросы:</strong> Если API получает запрос с ошибкой, вернётся заголовок HTTP с ключом \"MediaWiki-API-Error\", после чего значение заголовка и код ошибки будут отправлены обратно и установлены в то же значение. Более подробную информацию см. [[mw:API:Errors_and_warnings|API: Ошибки и предупреждения]].",
        "apihelp-main-param-action": "Действие, которое следует выполнить.",
        "apihelp-main-param-format": "Формат вывода.",
-       "apihelp-main-param-smaxage": "УÑ\81Ñ\82анавливаеÑ\82 Ð·Ð°Ð³Ð¾Ð»Ð¾Ð²Ð¾Ðº <code>s-maxage</code> в заданное число секунд. Ошибки никогда не кэшируются.",
-       "apihelp-main-param-maxage": "УÑ\81Ñ\82анавливаеÑ\82 Ð·Ð°Ð³Ð¾Ð»Ð¾Ð²Ð¾Ðº <code>max-age</code> в заданное число секунд. Ошибки никогда не кэшируются.",
+       "apihelp-main-param-smaxage": "УÑ\81Ñ\82анавливаеÑ\82 Ð·Ð½Ð°Ñ\87ение HTTP-заголовка Cache-Control <code>s-maxage</code> в заданное число секунд. Ошибки никогда не кэшируются.",
+       "apihelp-main-param-maxage": "УÑ\81Ñ\82анавливаеÑ\82 Ð·Ð½Ð°Ñ\87ение HTTP-заголовка Cache-Control <code>s-maxage</code> в заданное число секунд. Ошибки никогда не кэшируются.",
        "apihelp-main-param-assert": "Удостовериться, что пользователь авторизован, если задано <kbd>user</kbd>, или что имеет права бота, если задано <kbd>bot</kbd>.",
        "apihelp-main-param-requestid": "Любое заданное здесь значение будет включено в ответ. Может быть использовано для различения запросов.",
        "apihelp-main-param-servedby": "Включить в результаты имя хоста, обработавшего запрос.",
index f0c4542..dd3fb8f 100644 (file)
        "apihelp-options-example-reset": "重置所有用户设置。",
        "apihelp-options-example-change": "更改<kbd>skin</kbd>和<kbd>hideminor</kbd>设置。",
        "apihelp-options-example-complex": "重置所有设置,然后设置<kbd>skin</kbd>和<kbd>nickname</kbd>。",
-       "apihelp-paraminfo-description": "è\8e·å\8f\96å\85³äº\8e API 模块的信息。",
+       "apihelp-paraminfo-description": "è\8e·å¾\97å\85³äº\8eAPI模块的信息。",
        "apihelp-paraminfo-param-modules": "模块名称(<var>action</var>和<var>format</var>参数值,或<kbd>main</kbd>)的列表。可通过<kbd>+</kbd>指定子模块。",
        "apihelp-paraminfo-param-helpformat": "帮助字符串的格式。",
        "apihelp-paraminfo-param-querymodules": "查询模块名称(<var>prop</var>、<var>meta</var>或<var>list</var>参数值)的列表。使用<kbd>$1modules=query+foo</kbd>而不是<kbd>$1querymodules=foo</kbd>。",
        "apihelp-parse-paramvalue-prop-indicators": "提供页面上使用的页面状态指示器的HTML。",
        "apihelp-parse-paramvalue-prop-iwlinks": "在被解析的wiki文本中提供跨wiki链接。",
        "apihelp-parse-paramvalue-prop-wikitext": "提供被解析的原始wiki文本。",
+       "apihelp-parse-paramvalue-prop-properties": "提供多种定义在被解析的wiki文本中的属性。",
        "apihelp-parse-paramvalue-prop-limitreportdata": "以结构化的方式提供限制报告。如果<var>$1disablelimitreport</var>被设定则不提供数据。",
        "apihelp-parse-paramvalue-prop-limitreporthtml": "提供限制报告的HTML版本。当<var>$1disablelimitreport</var>被设置时不会提供数据。",
        "apihelp-parse-paramvalue-prop-parsetree": "修订内容的XML解析树(需要内容模型<code>$1</code>)",
        "apihelp-query+alllinks-param-namespace": "要列举的名字空间。",
        "apihelp-query+alllinks-param-limit": "总共要返回多少个项目。",
        "apihelp-query+alllinks-param-dir": "列出方向。",
+       "apihelp-query+alllinks-example-B": "列出链接的标题,包括丢失的,带它们来自的页面ID,以<kbd>B</kbd>开头。",
        "apihelp-query+alllinks-example-unique": "列出唯一的链接标题。",
        "apihelp-query+alllinks-example-unique-generator": "获取所有已链接的标题,标记缺少的。",
        "apihelp-query+alllinks-example-generator": "获取包含这些链接的页面。",
        "apihelp-query+allredirects-param-from": "要列举的起始重定向标题。",
        "apihelp-query+allredirects-param-to": "要列举的最终重定向标题。",
        "apihelp-query+allredirects-param-prefix": "搜索所有以此值开头的目标页面。",
+       "apihelp-query+allredirects-param-unique": "只显示明显的目标页面。不能与$1prop=ids|fragment|interwiki一起使用。\n当作为生成器使用时,产生目标页面而不是来源页面。",
        "apihelp-query+allredirects-param-prop": "要包含的信息束:",
        "apihelp-query+allredirects-paramvalue-prop-ids": "添加重定向页面的页面ID(不能与<var>$1unique</var>一起使用)。",
        "apihelp-query+allredirects-paramvalue-prop-title": "添加重定向的标题。",
        "apihelp-query+alltransclusions-param-from": "要列举的起始嵌入标题。",
        "apihelp-query+alltransclusions-param-to": "要列举的最终嵌入标题。",
        "apihelp-query+alltransclusions-param-prefix": "搜索所有以此值开头的嵌入的标题。",
+       "apihelp-query+alltransclusions-param-unique": "只显示明显的被嵌入标题。不能与$1prop=ids一起使用。\n当作为生成器使用时,产生目标页面而不是来源页面。",
        "apihelp-query+alltransclusions-param-prop": "要包含的信息束:",
        "apihelp-query+alltransclusions-paramvalue-prop-ids": "添加嵌入中的页面的页面ID(不能与$1unique一起使用)。",
        "apihelp-query+alltransclusions-paramvalue-prop-title": "添加嵌入的标题。",
        "apihelp-query+logevents-paramvalue-prop-details": "列举有关日志事件的额外详细信息。",
        "apihelp-query+logevents-paramvalue-prop-tags": "列举用于日志活动的标签。",
        "apihelp-query+logevents-param-type": "过滤日志记录至仅限此类型。",
-       "apihelp-query+logevents-param-action": "过滤日志操作为仅限此操作。覆盖<var>$1type</var>。类似<kbd>action/*</kbd>的通配符操作允许指定用于星号的任意字符串。",
+       "apihelp-query+logevents-param-action": "过滤日志操作为仅限此操作。覆盖<var>$1type</var>。在可用值列表中,带星号通配符的值例如<kbd>action/*</kbd>可在斜线(/)后拥有不同字符串。",
        "apihelp-query+logevents-param-start": "枚举的起始时间戳。",
        "apihelp-query+logevents-param-end": "枚举的结束时间戳。",
        "apihelp-query+logevents-param-user": "过滤记录为这些由指定用户做出的。",
        "apihelp-query+protectedtitles-example-generator": "找到主命名空间中已保护的标题的链接。",
        "apihelp-query+querypage-param-limit": "返回的结果数。",
        "apihelp-query+querypage-example-ancientpages": "返回[[Special:Ancientpages]]的结果。",
-       "apihelp-query+random-description": "获取一组随机页面。\n\n页面列举在一个固定序列中,只有起始点是随机的。这意味着如果<samp>Main Page</samp>是列表中第一个随机页面的话,<samp>List of fictional monkeys</samp>将<em>总是</em>第二个,<samp>List of people on stamps of Vanuatu</samp>是第三个等。\n\n如果名字空间中的页面数低于<var>$1limit</var>,将只会返回少量的页面。同一页面不会返回两次。",
+       "apihelp-query+random-description": "获取一组随机页面。\n\n页面列举在一个固定序列中,只有起始点是随机的。这意味着如果<samp>Main Page</samp>是列表中第一个随机页面的话,<samp>List of fictional monkeys</samp>将<em>总是</em>第二个,<samp>List of people on stamps of Vanuatu</samp>是第三个等。",
        "apihelp-query+random-param-namespace": "只返回这些名字空间的页面。",
        "apihelp-query+random-param-limit": "限制返回多少随机页面。",
-       "apihelp-query+random-param-redirect": "加载一个随机重定向而不是一个随机页面。",
+       "apihelp-query+random-param-redirect": "请改用<kbd>$1filterredir=redirects</kbd>。",
+       "apihelp-query+random-param-filterredir": "如何过滤重定向。",
        "apihelp-query+random-example-simple": "从主名字空间返回两个随机页面。",
        "apihelp-query+random-example-generator": "返回有关来自主名字空间的两个随机页面的页面信息。",
        "apihelp-query+recentchanges-description": "枚举最近更改。",
        "apihelp-undelete-description": "恢复一个被删除页面的修订。\n\n被删除修订的列表(包括时间戳)可通过[[Special:ApiHelp/query+deletedrevs|list=deletedrevs]]检索到,并且被删除的文件ID列表可通过[[Special:ApiHelp/query+filearchive|list=filearchive]]检索到。",
        "apihelp-undelete-param-title": "要恢复的页面标题。",
        "apihelp-undelete-param-reason": "恢复的原因。",
+       "apihelp-undelete-param-timestamps": "要回复的修订的时间戳。如果<var>$1timestamps</var>和<var>$1fileids</var>都为空,所有将被恢复。",
        "apihelp-undelete-param-fileids": "要恢复的文件修订ID。如果<var>$1timestamps</var>和<var>$1fileids</var>都为空,所有将被恢复。",
        "apihelp-undelete-example-page": "恢复页面<kbd>Main Page</kbd>。",
        "apihelp-undelete-example-revisions": "恢复<kbd>Main Page</kbd>的两个修订。",
        "apihelp-userrights-example-userid": "将ID为<kbd>123</kbd>的用户加入至<kbd>机器人</kbd>组,并将其从<kbd>管理员</kbd>和<kbd>行政员</kbd>组移除。",
        "apihelp-watch-description": "从当前用户的监视列表中添加或移除页面。",
        "apihelp-watch-param-title": "要(取消)监视的页面。也可使用<var>$1titles</var>。",
+       "apihelp-watch-param-unwatch": "如果设置页面将被取消监视而不是被监视。",
        "apihelp-watch-example-watch": "监视页面<kbd>Main Page</kbd>。",
        "apihelp-watch-example-unwatch": "取消监视页面<kbd>Main Page</kbd>。",
        "apihelp-watch-example-generator": "监视主名字空间中的最少几个页面。",
        "api-help-param-type-boolean": "类型:布尔值([[Special:ApiHelp/main#main/datatypes|详细信息]])",
        "api-help-param-type-timestamp": "类型:{{PLURAL:$1|1=时间戳|2=时间戳列表}}([[Special:ApiHelp/main#main/datatypes|允许格式]])",
        "api-help-param-type-user": "类型:{{PLURAL:$1|1=用户名|2=用户名列表}}",
-       "api-help-param-list": "{{PLURAL:$1|1=ä¸\80个å\80¼|2=值(以<kbd>{{!}}</kbd>分隔)}}:$2",
+       "api-help-param-list": "{{PLURAL:$1|1=以ä¸\8bå\80¼ä¸­ç\9a\84ä¸\80个|2=值(以<kbd>{{!}}</kbd>分隔)}}:$2",
        "api-help-param-list-can-be-empty": "{{PLURAL:$1|0=必须为空|可以为空,或$2}}",
        "api-help-param-limit": "不允许超过$1。",
        "api-help-param-limit2": "不允许超过$1个(对于机器人则是$2个)。",
index e5916bd..3f106bd 100644 (file)
@@ -270,6 +270,17 @@ class EnhancedChangesList extends ChangesList {
 
                $queryParams['curid'] = $curId;
 
+               # Sub-entries
+               $lines = '';
+               foreach ( $block as $i => $rcObj ) {
+                       $line = $this->getLineData( $block, $rcObj, $queryParams );
+                       $lines .= $line;
+                       if ( !$line ) {
+                               // completely ignore this RC entry if we don't want to render it
+                               unset( $block[$i] );
+                       }
+               }
+
                $r .= $this->getLogText( $block, $queryParams, $allLogs, $isnew, $namehidden );
 
                $r .= ' <span class="mw-changeslist-separator">. .</span> ';
@@ -299,116 +310,133 @@ class EnhancedChangesList extends ChangesList {
                $r .= $this->numberofWatchingusers( $block[0]->numberofWatchingusers );
                $r .= '</td></tr>';
 
-               # Sub-entries
-               foreach ( $block as $rcObj ) {
-                       # Classes to apply -- TODO implement
-                       $classes = array();
-                       $type = $rcObj->mAttribs['rc_type'];
-                       $data = array();
-
-                       $trClass = $rcObj->watched && $rcObj->mAttribs['rc_timestamp'] >= $rcObj->watched
-                               ? ' class="mw-enhanced-watched"' : '';
-                       $separator = ' <span class="mw-changeslist-separator">. .</span> ';
-
-                       $data['recentChangesFlags'] = array(
-                               'newpage' => $type == RC_NEW,
-                               'minor' => $rcObj->mAttribs['rc_minor'],
-                               'unpatrolled' => $rcObj->unpatrolled,
-                               'bot' => $rcObj->mAttribs['rc_bot'],
-                       );
+               if ( !$lines ) {
+                       // if there are no lines to be rendered (all aborted by hook), don't render the block
+                       return '';
+               }
 
-                       $params = $queryParams;
+               $r .= $lines;
+               $r .= "</table>\n";
 
-                       if ( $rcObj->mAttribs['rc_this_oldid'] != 0 ) {
-                               $params['oldid'] = $rcObj->mAttribs['rc_this_oldid'];
-                       }
+               $this->rcCacheIndex++;
+
+               return $r;
+       }
 
-                       # Log timestamp
-                       if ( $type == RC_LOG ) {
-                               $link = $rcObj->timestamp;
+       /**
+        * @param RCCacheEntry[] $block
+        * @param RCCacheEntry $rcObj
+        * @param array $queryParams
+        * @return string
+        * @throws Exception
+        * @throws FatalError
+        * @throws MWException
+        */
+       protected function getLineData( array $block, RCCacheEntry $rcObj, array $queryParams = array() ) {
+               $RCShowChangedSize = $this->getConfig()->get( 'RCShowChangedSize' );
+
+               # Classes to apply -- TODO implement
+               $classes = array();
+               $type = $rcObj->mAttribs['rc_type'];
+               $data = array();
+
+               $trClass = $rcObj->watched && $rcObj->mAttribs['rc_timestamp'] >= $rcObj->watched
+                       ? ' class="mw-enhanced-watched"' : '';
+               $separator = ' <span class="mw-changeslist-separator">. .</span> ';
+
+               $data['recentChangesFlags'] = array(
+                       'newpage' => $type == RC_NEW,
+                       'minor' => $rcObj->mAttribs['rc_minor'],
+                       'unpatrolled' => $rcObj->unpatrolled,
+                       'bot' => $rcObj->mAttribs['rc_bot'],
+               );
+
+               $params = $queryParams;
+
+               if ( $rcObj->mAttribs['rc_this_oldid'] != 0 ) {
+                       $params['oldid'] = $rcObj->mAttribs['rc_this_oldid'];
+               }
+
+               # Log timestamp
+               if ( $type == RC_LOG ) {
+                       $link = $rcObj->timestamp;
                        # Revision link
-                       } elseif ( !ChangesList::userCan( $rcObj, Revision::DELETED_TEXT, $this->getUser() ) ) {
-                               $link = '<span class="history-deleted">' . $rcObj->timestamp . '</span> ';
-                       } else {
-                               $link = Linker::linkKnown(
-                                       $rcObj->getTitle(),
-                                       $rcObj->timestamp,
-                                       array(),
-                                       $params
-                               );
-                               if ( $this->isDeleted( $rcObj, Revision::DELETED_TEXT ) ) {
-                                       $link = '<span class="history-deleted">' . $link . '</span> ';
-                               }
+               } elseif ( !ChangesList::userCan( $rcObj, Revision::DELETED_TEXT, $this->getUser() ) ) {
+                       $link = '<span class="history-deleted">' . $rcObj->timestamp . '</span> ';
+               } else {
+                       $link = Linker::linkKnown(
+                               $rcObj->getTitle(),
+                               $rcObj->timestamp,
+                               array(),
+                               $params
+                       );
+                       if ( $this->isDeleted( $rcObj, Revision::DELETED_TEXT ) ) {
+                               $link = '<span class="history-deleted">' . $link . '</span> ';
                        }
-                       $data['timestampLink'] = $link;
+               }
+               $data['timestampLink'] = $link;
 
-                       $currentAndLastLinks = '';
-                       if ( !$type == RC_LOG || $type == RC_NEW ) {
-                               $currentAndLastLinks .= ' ' . $this->msg( 'parentheses' )->rawParams(
+               $currentAndLastLinks = '';
+               if ( !$type == RC_LOG || $type == RC_NEW ) {
+                       $currentAndLastLinks .= ' ' . $this->msg( 'parentheses' )->rawParams(
                                        $rcObj->curlink .
-                                               $this->message['pipe-separator'] .
-                                               $rcObj->lastlink
+                                       $this->message['pipe-separator'] .
+                                       $rcObj->lastlink
                                )->escaped();
-                       }
-                       $data['currentAndLastLinks'] = $currentAndLastLinks;
-                       $data['separatorAfterCurrentAndLastLinks'] = $separator;
-
-                       # Character diff
-                       if ( $RCShowChangedSize ) {
-                               $cd = $this->formatCharacterDifference( $rcObj );
-                               if ( $cd !== '' ) {
-                                       $data['characterDiff'] = $cd;
-                                       $data['separatorAfterCharacterDiff'] = $separator;
-                               }
-                       }
+               }
+               $data['currentAndLastLinks'] = $currentAndLastLinks;
+               $data['separatorAfterCurrentAndLastLinks'] = $separator;
 
-                       if ( $rcObj->mAttribs['rc_type'] == RC_LOG ) {
-                               $data['logEntry'] = $this->insertLogEntry( $rcObj );
-                       } else {
-                               # User links
-                               $data['userLink'] = $rcObj->userlink;
-                               $data['userTalkLink'] = $rcObj->usertalklink;
-                               $data['comment'] = $this->insertComment( $rcObj );
+               # Character diff
+               if ( $RCShowChangedSize ) {
+                       $cd = $this->formatCharacterDifference( $rcObj );
+                       if ( $cd !== '' ) {
+                               $data['characterDiff'] = $cd;
+                               $data['separatorAfterCharacterDiff'] = $separator;
                        }
+               }
 
-                       # Rollback
-                       $data['rollback'] = $this->getRollback( $rcObj );
-
-                       # Tags
-                       $data['tags'] = $this->getTags( $rcObj, $classes );
+               if ( $rcObj->mAttribs['rc_type'] == RC_LOG ) {
+                       $data['logEntry'] = $this->insertLogEntry( $rcObj );
+               } else {
+                       # User links
+                       $data['userLink'] = $rcObj->userlink;
+                       $data['userTalkLink'] = $rcObj->usertalklink;
+                       $data['comment'] = $this->insertComment( $rcObj );
+               }
 
-                       // give the hook a chance to modify the data
-                       $success = Hooks::run( 'EnhancedChangesListModifyLineData',
-                               array( $this, &$data, $block, $rcObj ) );
-                       if ( !$success ) {
-                               // skip entry if hook aborted it
-                               continue;
-                       }
+               # Rollback
+               $data['rollback'] = $this->getRollback( $rcObj );
 
-                       $line = '<tr' . $trClass . '><td></td><td class="mw-enhanced-rc">';
-                       if ( isset( $data['recentChangesFlags'] ) ) {
-                               $line .= $this->recentChangesFlags( $data['recentChangesFlags'] );
-                               unset( $data['recentChangesFlags'] );
-                       }
-                       $line .= '&#160;</td><td class="mw-enhanced-rc-nested">';
-
-                       if ( isset( $data['timestampLink'] ) ) {
-                               $line .= '<span class="mw-enhanced-rc-time">' . $data['timestampLink'] . '</span>';
-                               unset( $data['timestampLink'] );
-                       }
+               # Tags
+               $data['tags'] = $this->getTags( $rcObj, $classes );
 
-                       // everything else: makes it easier for extensions to add or remove data
-                       $line .= implode( '', $data );
+               // give the hook a chance to modify the data
+               $success = Hooks::run( 'EnhancedChangesListModifyLineData',
+                       array( $this, &$data, $block, $rcObj ) );
+               if ( !$success ) {
+                       // skip entry if hook aborted it
+                       return '';
+               }
 
-                       $line .= "</td></tr>\n";
+               $line = '<tr' . $trClass . '><td></td><td class="mw-enhanced-rc">';
+               if ( isset( $data['recentChangesFlags'] ) ) {
+                       $line .= $this->recentChangesFlags( $data['recentChangesFlags'] );
+                       unset( $data['recentChangesFlags'] );
+               }
+               $line .= '&#160;</td><td class="mw-enhanced-rc-nested">';
 
-                       $r .= $line;
+               if ( isset( $data['timestampLink'] ) ) {
+                       $line .= '<span class="mw-enhanced-rc-time">' . $data['timestampLink'] . '</span>';
+                       unset( $data['timestampLink'] );
                }
-               $r .= "</table>\n";
 
-               $this->rcCacheIndex++;
+               // everything else: makes it easier for extensions to add or remove data
+               $line .= implode( '', $data );
 
-               return $r;
+               $line .= "</td></tr>\n";
+
+               return $line;
        }
 
        /**
index 117bd2d..ec0573e 100644 (file)
@@ -331,7 +331,7 @@ class RedisConnectionPool implements LoggerAwareInterface {
         * @deprecated since 1.23
         */
        public function handleException( $server, RedisConnRef $cref, RedisException $e ) {
-               return $this->handleError( $cref, $e );
+               $this->handleError( $cref, $e );
        }
 
        /**
index fa1c462..ce0360f 100644 (file)
@@ -387,6 +387,8 @@ abstract class FileBackend {
 
        /**
         * @see FileBackend::doOperations()
+        * @param array $ops
+        * @param array $opts
         */
        abstract protected function doOperationsInternal( array $ops, array $opts );
 
@@ -620,6 +622,7 @@ abstract class FileBackend {
 
        /**
         * @see FileBackend::doQuickOperations()
+        * @param array $ops
         * @since 1.20
         */
        abstract protected function doQuickOperationsInternal( array $ops );
@@ -765,6 +768,7 @@ abstract class FileBackend {
 
        /**
         * @see FileBackend::prepare()
+        * @param array $params
         */
        abstract protected function doPrepare( array $params );
 
@@ -795,6 +799,7 @@ abstract class FileBackend {
 
        /**
         * @see FileBackend::secure()
+        * @param array $params
         */
        abstract protected function doSecure( array $params );
 
@@ -827,6 +832,7 @@ abstract class FileBackend {
 
        /**
         * @see FileBackend::publish()
+        * @param array $params
         */
        abstract protected function doPublish( array $params );
 
@@ -852,6 +858,7 @@ abstract class FileBackend {
 
        /**
         * @see FileBackend::clean()
+        * @param array $params
         */
        abstract protected function doClean( array $params );
 
index 3677a14..f40d216 100644 (file)
@@ -213,14 +213,15 @@ abstract class File implements IDBAccessObject {
        }
 
        /**
-        * Normalize a file extension to the common form, and ensure it's clean.
-        * Extensions with non-alphanumeric characters will be discarded.
+        * Normalize a file extension to the common form, making it lowercase and checking some synonyms,
+        * and ensure it's clean. Extensions with non-alphanumeric characters will be discarded.
+        * Keep in sync with mw.Title.normalizeExtension() in JS.
         *
-        * @param string $ext (without the .)
-        * @return string
+        * @param string $extension File extension (without the leading dot)
+        * @return string File extension in canonical form
         */
-       static function normalizeExtension( $ext ) {
-               $lower = strtolower( $ext );
+       static function normalizeExtension( $extension ) {
+               $lower = strtolower( $extension );
                $squish = array(
                        'htm' => 'html',
                        'jpeg' => 'jpg',
index 201ef71..13755e3 100644 (file)
        "config-license-cc-by": "المشاع الإبداعي النسبة للمؤلف",
        "config-license-cc-by-nc-sa": "المشاع الإبداعي النسبة للمؤلف غير تجاري المشاركة بالمثل",
        "config-license-pd": "ملكية عامة",
+       "config-license-cc-choose": "اختر ترخيص مشاع إبداعي مخصص",
        "config-email-settings": "إعدادات البريد الإلكتروني",
        "config-email-usertalk": "فعل إخطارات صفحات نقاش المستخدمين",
        "config-email-watchlist": "تمكين إشعارات قائمة المراقبة",
index cbe64d6..aa24362 100644 (file)
                        "Nemo bis",
                        "Ricordisamoa",
                        "Fpugliajno",
-                       "The Polish"
+                       "The Polish",
+                       "Sannita"
                ]
        },
-       "config-desc": "Il programma di installazione per MediaWiki",
+       "config-desc": "Programma di installazione per MediaWiki",
        "config-title": "Installazione di MediaWiki $1",
        "config-information": "Informazioni",
        "config-localsettings-upgrade": "È stato rilevato un file <code>LocalSettings.php</code>.\nPer aggiornare questa installazione, si prega di inserire il valore di <code>$wgUpgradeKey</code> nella casella qui sotto.\nLo potete trovare in <code>LocalSettings.php</code>.",
index b998e34..bffdf05 100644 (file)
        "config-email-sender": "De Adräß för de Antwoote op <i lang=\"en\">e-mails</i>:",
        "config-email-sender-help": "Jiff de Adräß för de <i lang=\"en\">e-mail</i> en, woh Antwoote ob em Wiki singe <i lang=\"en\">e-mails</i> hen jonn sulle.\nDat es och de Adräß, woh de <i lang=\"en\">e-mails</i> met Fählermäldonge hen jon.\nVill ẞöövere för de <i lang=\"en\">e-mail</i> welle winnischßdens ene jöltijje Domain en dä Adräß han.",
        "config-upload-settings": "Belder un Datteie huh laade",
-       "config-upload-enable": "Belder un Datteie huh laade zohlohße",
+       "config-upload-enable": "Et Belder un Datteie Huhlahde zohlohße",
        "config-upload-help": "Datteije huh ze laade künnt e Risiko för dem ẞööver singe Sescherheit sin.\nMieh doh drövver kam_mer em [//www.mediawiki.org/wiki/Special:MyLanguage/Manual:Security Kapitel övver de Sescherheit] em Handbooch lässe.\n\nÖm et Huhlaade zohzelohße donn de Rääschde för der Zohjreff op dat Ongerverzeischneß <code lang=\"en\">images</code> em MediaWiki singem Houpverzeischneß esu enshtälle, dat et Webßööverprojramm doh Datteije un Verzeischneße eren schrieve kann.\nDonoh donn heh di Saach zohlohße.",
        "config-upload-deleted": "Dat Verzeishneß för fottjeschmeße Datteije:",
        "config-upload-deleted-help": "Söhk e Verzeijschneß uß för de fottjeschmeße Datteije vum Wiki dren afzelääje.\nEt bäß es, wam_mer vum <i lang=\"en\">world wide web</i> doh nit drahn kumme kann.",
        "config-install-extension-tables": "Ben Datebangk-Tabälle för de Zohsazprojramme aam ennreschte",
        "config-install-mainpage-failed": "Kunnt de Houpsigg nit afshpeishere: $1",
        "config-install-done": "'''Jlöckwonsch!'''\nMediaWiki es jetz enstalleet.\n\nEt Projramm zom Enreeschte hät en Dattei <code lang=\"en\">LocalSettings.php</code> aanjelaat.\nDoh sin de Enstellunge vum Wiki dren.\n\nDo weeß se eronge laade möße un dann en dem Wiki sing Aanfangsverzeishnes donn möße, et sellve Verzeisneß, woh di Dattei <code lang=\"en\">index.php</code> dren litt. Dat Erongerlaade sullt automattesch aanjefange han.\n\nWann domet jet nit jeflupp hät, udder De di Dattei norr_ens han wells, donn op dä Lengk heh dronger klecke:\n\n$3\n\n'''Opjepaß''': Wann De dat jez nit deihß, es alles verschött, wat De bes jöz enjejovve häs, weil di Dattei fott es en däm Momang, woh heh dat Projamm aam Engk es.\n\nWann De mem Ronger- un widder Huhlaade fäädesh bes, kanns De '''[$2 en Ding Wiki jonn]'''.",
-       "config-download-localsettings": "Donn di Dattei <code lang=\"en\">LocalSettings.php</code> eronger laade",
+       "config-download-localsettings": "Donn di Dattei <code lang=\"en\" xml:lang=\"en\" dir=\"ltr\">LocalSettings.php</code> eronger lahde",
        "config-help": "Hölp",
        "config-help-tooltip": "Donn Hölp heh aan däm Plaaz enblände.",
        "config-nofile": "De Dattei „$1“ ham_mer nit jefonge. Es di fottjeschmeße?",
diff --git a/includes/installer/i18n/olo.json b/includes/installer/i18n/olo.json
new file mode 100644 (file)
index 0000000..9f8743c
--- /dev/null
@@ -0,0 +1,59 @@
+{
+       "@metadata": {
+               "authors": [
+                       "Mashoi7"
+               ]
+       },
+       "config-your-language": "Sinun kieli:",
+       "config-wiki-language": "Wikin kieli:",
+       "config-back": "← Järilleh",
+       "config-continue": "Jatka →",
+       "config-page-language": "Kieli",
+       "config-page-welcome": "Tule terveh MediaWikih!",
+       "config-page-dbconnect": "Yhtistä tiedokandah",
+       "config-page-dbsettings": "Tiedokanduazetukset",
+       "config-page-name": "Nimi",
+       "config-page-options": "Azetukset",
+       "config-page-install": "Azenda",
+       "config-page-complete": "Valmis!",
+       "config-page-readme": "Luve minut",
+       "config-page-copying": "Kopiruitah",
+       "config-page-upgradedoc": "Päivitetäh",
+       "config-page-existingwiki": "Olemasolii wiki",
+       "config-restart": "Muga, käynnistä uvvelleh",
+       "config-env-php": "PHP $1 on azendettu.",
+       "config-env-hhvm": "HHVM $1 on azendettu.",
+       "config-db-name": "Tiedokannan nimi:",
+       "config-db-username": "Tiedokannan käyttäinimi:",
+       "config-db-password": "Tiedokannan peittosana:",
+       "config-type-mssql": "Microsoft SQL Server",
+       "config-header-mysql": "MySQL-azetukset",
+       "config-header-postgres": "PostgreSQL-azetukset",
+       "config-header-sqlite": "SQLite-azetukset",
+       "config-header-oracle": "Oracle-azetukset",
+       "config-header-mssql": "Microsoft SQL Server azetukset",
+       "config-mysql-innodb": "InnoDB",
+       "config-mysql-myisam": "MyISAM",
+       "config-mysql-utf8": "UTF-8",
+       "config-site-name": "Wikin nimi:",
+       "config-site-name-blank": "Kirjuta sivun nimi.",
+       "config-project-namespace": "Projektan nimitila:",
+       "config-ns-generic": "Projektu",
+       "config-ns-other-default": "MinunWiki",
+       "config-admin-name": "Sinun käyttäitunnus:",
+       "config-admin-password": "Peittosana:",
+       "config-admin-password-confirm": "Peittosana myös:",
+       "config-admin-name-blank": "Kirjuta administruattoran käyttäinimi.",
+       "config-admin-password-blank": "Kirjuta administruattorutilin peittosana.",
+       "config-admin-password-mismatch": "Sinun kirjutetut kaksi peittosanua ei oldu yhtenjyttymät.",
+       "config-admin-email": "Sähköpoštuadressu:",
+       "config-optional-continue": "Kyzy minuspäi ližiä kyzymyksii.",
+       "config-optional-skip": "Olen jo terstavunnuh, vaiku azenda wiki.",
+       "config-email-settings": "Sähköpoštuazetukset",
+       "config-logo": "Logon URL:",
+       "config-skins": "Ketut",
+       "config-install-step-done": "ruattu",
+       "config-install-user-alreadyexists": "Käyttäi \"$1\" on jo olemas",
+       "config-help": "abu",
+       "config-nofile": "Failua \"$1\" ei löydynyh. Ongo se otettu iäre?"
+}
index 4d9fa38..27dddd3 100644 (file)
@@ -16,7 +16,8 @@
                        "Marcos dias de oliveira",
                        "Fasouzafreitas",
                        "TheEduGobi",
-                       "Dianakc"
+                       "Dianakc",
+                       "Walesson"
                ]
        },
        "config-desc": "O instalador do MediaWiki",
@@ -65,7 +66,7 @@
        "config-unicode-using-intl": "Usando a [http://pecl.php.net/intl extensão intl PECL] para a normalização Unicode.",
        "config-unicode-pure-php-warning": "<strong>Aviso</strong>: A [http://pecl.php.net/intl extensão intl PECL] não está disponível para efetuar a normalização Unicode, abortando e passando para a lenta implementação de PHP puro.\nSe o seu site tem um alto volume de tráfego, informe-se sobre a [//www.mediawiki.org/wiki/Special:MyLanguage/Unicode_normalization_considerations normalização Unicode].",
        "config-unicode-update-warning": "<strong>Aviso:</strong> A versão instalada do wrapper de normalização Unicode usa uma versão mais antiga da biblioteca do [//www.site.icu-project.org/projeto ICU].\nVocê deve [//www.mediawiki.org/wiki/Special:MyLanguage/Unicode_normalization_considerations atualizar] se você tem quaisquer preocupações com o uso do Unicode.",
-       "config-no-db": "Não foi possível encontrar um driver de banco de dados adequado! É necessário instalar um driver de banco de dados para o PHP.\nSão suportados os seguintes tipos de bancos de dados: $1.\n\nSe você mesmo tiver compilado o PHP, reconfigure-o com um cliente de banco de dados ativado usando, por exemplo <code>./configure --with-mysqli</code>.\nSe você instalou o PHP a partir de um pacote do Debian ou do Ubuntu, então será também necessário instalar, por exemplo, o pacote <code>php5-mysql</code>.",
+       "config-no-db": "Não foi possível localizar um driver de banco de dados apropriado! Você precisa instalar um driver de banco de dados para PHP. O banco de dados seguinte {{PLURAL: $ 2 | | tipo é tipos são}} suportado: $ 1. Se você compilou o PHP mesmo, reconfigurá-lo com um cliente de banco de dados ativada, por exemplo, usando <code> ./ configure --with-mysqli </ code>. Se você instalou o PHP a partir de um pacote Debian ou Ubuntu, então você também precisa instalar, por exemplo, o <code> php5-mysql </ code> pacote.",
        "config-outdated-sqlite": "<strong>Aviso:</strong> você tem o SQLite versão $1, que é menor do que a versão mínima necessária $2. O SQLite não estará disponível.",
        "config-no-fts3": "<strong>Aviso</strong> O SQLite foi compilado sem o [//sqlite.org/fts3.html módulo FTS3], as funcionalidades de pesquisa não estarão disponíveis nesta instalação.",
        "config-register-globals-error": "<strong>Erro: a opção <code>[http://php.net/register_globals register_globals]</code> do PHP está ativada.\nA mesma deve ser desativada para continuar a instalação.</strong>\nVeja [https://www.mediawiki.org/wiki/register_globals https://www.mediawiki.org/wiki/register_globals] para obter ajuda com isto.",
@@ -74,7 +75,7 @@
        "config-magic-quotes-sybase": "<strong>Erro fatal: A opção [http://www.php.net/manual/en/ref.info.php#ini.magic-quotes-sybase magic_quotes_sybase] está ativada!</strong>\nEsta opção corrompe os dados de entrada de forma imprevisível.\nVocê não pode instalar ou utilizar o MediaWiki a menos que esta opção seja desativada.",
        "config-mbstring": "<strong>Erro fatal: A opção [http://www.php.net/manual/en/ref.mbstring.php#mbstring.overload mbstring.func_overload] está ativada!</strong>\nEsta opção causa erros e pode corromper os dados de forma imprevisível.\nVocê não pode instalar ou utilizar o MediaWiki a menos que esta opção seja desativada.",
        "config-safe-mode": "<strong>Aviso:</strong> O [http://www.php.net/features.safe-mode safe mode] do PHP está ativado.\nEste modo pode causar problemas, especialmente no upload de arquivos e no suporte a <code>math</code>.",
-       "config-xml-bad": "O módulo XML do PHP está ausente.\nO MediaWiki necessita de funções deste módulo e não funcionará com esta configuração.\nSe está utilizando o Mandrake, instale o pacote php-xml.",
+       "config-xml-bad": "Módulo XML do PHP está faltando. MediaWiki requer funções deste módulo e não vai funcionar nesta configuração. Pode ser necessário instalar o pacote RPM php-xml.",
        "config-pcre-old": "<strong>Erro fatal:</strong> É necessário o PCRE $1 ou versão posterior.\nO binário do seu PHP foi vinculado com o PCRE $2.\n[https://www.mediawiki.org/wiki/Manual:Errors_and_symptoms/PCRE Mais informações].",
        "config-pcre-no-utf8": "<strong>Erro fatal:</strong> O módulo PCRE do PHP parece ser compilado sem suporte a PCRE_UTF8.\nO MediaWiki requer suporte a UTF-8 para funcionar corretamente.",
        "config-memory-raised": "A configuração <code>memory_limit</code> do PHP era $1; foi aumentada para $2.",
        "config-db-install-account": "Conta de usuário para instalação",
        "config-db-username": "Nome de usuário do banco de dados:",
        "config-db-password": "Senha do banco de dados:",
-       "config-db-password-empty": "Por favor digite uma senha para o novo usuário do banco de dados: $1. Embora seja possível criar usuários sem senha, isto não é seguro.",
-       "config-db-username-empty": "É necessário entrar um valor para \"{{int:config-db-username}}\".",
        "config-db-install-username": "Digite o nome de usuário que será utilizado para conectar com o banco de dados durante o processo de instalação.\nEste não é a conta de usuário do MediaWiki; este é o nome de usuário para sua base de dados.",
        "config-db-install-password": "Digite a senha que será utilizada para conectar com o banco de dados durante o processo de instalação.\nEsta não é a senha de usuário da conta do MediaWiki; esta será a senha para seu banco de dados.",
        "config-db-install-help": "Digite o nome de usuário e a senha que serão utilizados para conectar com o banco de dados durante o processo de instalação.",
index 89f2dd9..bb42d88 100644 (file)
@@ -82,7 +82,7 @@
        "config-memory-bad": "Parameters:\n* $1 is the configured <code>memory_limit</code>.",
        "config-ctype": "Message if support for [http://www.php.net/manual/en/ctype.installation.php Ctype] is missing from PHP.\n{{Related|Config-fatal}}",
        "config-iconv": "Message if support for [http://www.php.net/manual/en/iconv.installation.php iconv] is missing from PHP.\n{{Related|Config-fatal}}",
-       "config-json": "Message if support for [[wikipedia:JSON|JSON]] is missing from PHP.\n* \"[[wikipedia:Red Hat Enterprise Linux|Red Hat Enterprise Linux]]\" (RHEL) and \"[[wikipedia:CentOS|CentOS]]\" refer to two almost-identical Linux distributions. \"5 and 6\" refers to version 5 or 6 of either distribution. Because RHEL 7 likely will not include the PHP extension, do not translate as \"5 or newer\".\n* \"The [http://www.php.net/json PHP extension]\" is the JSON extension included with PHP 5.2 and newer.\n* \"The [http://pecl.php.net/package/jsonc PECL extension]\" is based on the PHP extension, though excludes code some distributions have found unacceptable (see [[bugzilla:47431]]).\n{{Related|Config-fatal}}",
+       "config-json": "Message if support for [[wikipedia:JSON|JSON]] is missing from PHP.\n* \"[[wikipedia:Red Hat Enterprise Linux|Red Hat Enterprise Linux]]\" (RHEL) and \"[[wikipedia:CentOS|CentOS]]\" refer to two almost-identical Linux distributions. \"5 and 6\" refers to version 5 or 6 of either distribution. Because RHEL 7 likely will not include the PHP extension, do not translate as \"5 or newer\".\n* \"The [http://www.php.net/json PHP extension]\" is the JSON extension included with PHP 5.2 and newer.\n* \"The [http://pecl.php.net/package/jsonc PECL extension]\" is based on the PHP extension, though excludes code some distributions have found unacceptable (see [[phab:T49431]]).\n{{Related|Config-fatal}}",
        "config-xcache": "Message indicates if this program is available",
        "config-apc": "Message indicates if this program is available",
        "config-wincache": "Message indicates if this program is available",
index 92b2d3b..e877280 100644 (file)
        "config-using-server": "באניצן סארווער־נאמען \"<nowiki>$1</nowiki>\".",
        "config-using-uri": "באניצן סארווער־אדרעס \"<nowiki>$1$2</nowiki>\".",
        "config-db-type": "דאטנבאזע טיפ:",
+       "config-db-host": "דאטנבאזע־סארווער:",
        "config-db-host-oracle": "דאטנבאזע־TNS:",
        "config-db-wiki-settings": "אידענטיפיצירן די דאזיקע וויקי",
        "config-db-name": "דאטנבאזע נאָמען:",
+       "config-db-install-account": "באניצער־קאנטע פאר אינסטאלאציע",
        "config-db-username": "דאטנבאזע באניצער־נאָמען:",
        "config-db-password": "דאטנבאזע־פאסווארט:",
+       "config-invalid-db-type": "אומגילטיגער דאטנבאזע־טיפ",
+       "config-missing-db-name": "איר דארפט איינגעבן א ווערט פאר \"{{int:config-db-name}}\".",
+       "config-missing-db-host": "איר דארפט איינגעבן א ווערט פאר \"{{int:config-db-host}}\".",
+       "config-missing-db-server-oracle": "איר דארפט איינגעבן א ווערט פאר \"{{int:config-db-host-oracle}}\".",
        "config-project-namespace": "פראיעקט נאָמענטייל:",
        "config-ns-generic": "פראיעקט",
        "config-admin-name": "אײַער באַניצער־נאָמען:",
index 2a179be..43dfab3 100644 (file)
@@ -54,6 +54,7 @@ class ParsoidVirtualRESTService extends VirtualRESTService {
                }
                // set up defaults and merge them with the given params
                $mparams = array_merge( array(
+                       'name' => 'parsoid',
                        'url' => 'http://localhost:8000/',
                        'prefix' => 'localhost',
                        'domain' => 'localhost',
index bc520aa..3a7bc58 100644 (file)
@@ -48,6 +48,7 @@ class RestbaseVirtualRESTService extends VirtualRESTService {
        public function __construct( array $params ) {
                // set up defaults and merge them with the given params
                $mparams = array_merge( array(
+                       'name' => 'restbase',
                        'url' => 'http://localhost:7231/',
                        'domain' => 'localhost',
                        'timeout' => 100,
index 011dabe..88b0e1f 100644 (file)
@@ -45,7 +45,11 @@ class SwiftVirtualRESTService extends VirtualRESTService {
         *   - swiftAuthTTL       : Swift authentication TTL (seconds)
         */
        public function __construct( array $params ) {
-               parent::__construct( $params );
+               // set up defaults and merge them with the given params
+               $mparams = array_merge( array(
+                       'name' => 'swift'
+               ), $params );
+               parent::__construct( $mparams );
        }
 
        /**
index 2a0b3f0..01a4ea6 100644 (file)
@@ -44,6 +44,17 @@ abstract class VirtualRESTService {
                $this->params = $params;
        }
 
+       /**
+        * Return the name of this service, in a form suitable for error
+        * reporting or debugging.
+        *
+        * @return string The name of the service behind this VRS object.
+        */
+       public function getName() {
+               return isset( $this->params['name'] ) ? $this->params['name'] :
+                       get_class( $this );
+       }
+
        /**
         * Prepare virtual HTTP(S) requests (for this service) for execution
         *
index 97aa796..1d8d777 100644 (file)
@@ -34,8 +34,6 @@ class XMPInfo {
                return self::$items;
        }
 
-       static private $ranHooks = false;
-
        /**
         * XMPInfo::$items keeps a list of all the items
         * we are interested to extract, as well as
index 7e6a4d7..1b2c8db 100644 (file)
@@ -236,8 +236,13 @@ class MemcachedPeclBagOStuff extends MemcachedBagOStuff {
        public function getMulti( array $keys, $flags = 0 ) {
                $this->debugLog( 'getMulti(' . implode( ', ', $keys ) . ')' );
                $callback = array( $this, 'encodeKey' );
-               $result = $this->client->getMulti( array_map( $callback, $keys ) );
-               $result = $result ?: array(); // must be an array
+               $encodedResult = $this->client->getMulti( array_map( $callback, $keys ) );
+               $encodedResult = $encodedResult ?: array(); // must be an array
+               $result = array();
+               foreach ( $encodedResult as $key => $value ) {
+                       $key = $this->decodeKey( $key );
+                       $result[$key] = $value;
+               }
                return $this->checkResult( false, $result );
        }
 
index 69792ad..6f0ba58 100644 (file)
@@ -59,7 +59,13 @@ class MemcachedPhpBagOStuff extends MemcachedBagOStuff {
 
        public function getMulti( array $keys, $flags = 0 ) {
                $callback = array( $this, 'encodeKey' );
-               return $this->client->get_multi( array_map( $callback, $keys ) );
+               $encodedResult = $this->client->get_multi( array_map( $callback, $keys ) );
+               $result = array();
+               foreach ( $encodedResult as $key => $value ) {
+                       $key = $this->decodeKey( $key );
+                       $result[$key] = $value;
+               }
+               return $result;
        }
 
        /**
index 62dd1e3..43b12b2 100644 (file)
@@ -709,7 +709,7 @@ EOT
                $out->addHTML( "<ul>\n" );
 
                # "Upload a new version of this file" link
-               $canUpload = $this->getTitle()->userCan( 'upload', $this->getContext()->getUser() );
+               $canUpload = $this->getTitle()->quickUserCan( 'upload', $this->getContext()->getUser() );
                if ( $canUpload && UploadBase::userCanReUpload(
                                $this->getContext()->getUser(),
                                $this->mPage->getFile()->name )
index e29ee88..807842b 100644 (file)
  * @ingroup Parser
  */
 
-/**
- * Class used to hide mw:editsection tokens from Tidy so that it doesn't break them
- * or break on them. This is a bit of a hack for now, but hopefully in the future
- * we may create a real postprocessor or something that will replace this.
- * It's called wrapper because for now it basically takes over MWTidy::tidy's task
- * of wrapping the text in a xhtml block
- *
- * This re-uses some of the parser's UNIQ tricks, though some of it is private so it's
- * duplicated. Perhaps we should create an abstract marker hiding class.
- *
- * @ingroup Parser
- */
-class MWTidyWrapper {
-
-       /**
-        * @var ReplacementArray
-        */
-       protected $mTokens;
-
-       protected $mMarkerIndex;
-
-       public function __construct() {
-               $this->mTokens = null;
-       }
-
-       /**
-        * @param string $text
-        * @return string
-        */
-       public function getWrapped( $text ) {
-               $this->mTokens = new ReplacementArray;
-               $this->mMarkerIndex = 0;
-
-               // Replace <mw:editsection> elements with placeholders
-               $wrappedtext = preg_replace_callback( ParserOutput::EDITSECTION_REGEX,
-                       array( &$this, 'replaceCallback' ), $text );
-               // ...and <mw:toc> markers
-               $wrappedtext = preg_replace_callback( '/\<\\/?mw:toc\>/',
-                       array( &$this, 'replaceCallback' ), $wrappedtext );
-               // ... and <math> tags
-               $wrappedtext = preg_replace_callback( '/\<math(.*?)\<\\/math\>/s',
-                       array( &$this, 'replaceCallback' ), $wrappedtext );
-               // Modify inline Microdata <link> and <meta> elements so they say <html-link> and <html-meta> so
-               // we can trick Tidy into not stripping them out by including them in tidy's new-empty-tags config
-               $wrappedtext = preg_replace( '!<(link|meta)([^>]*?)(/{0,1}>)!', '<html-$1$2$3', $wrappedtext );
-
-               // Wrap the whole thing in a doctype and body for Tidy.
-               $wrappedtext = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"' .
-                       ' "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html>' .
-                       '<head><title>test</title></head><body>' . $wrappedtext . '</body></html>';
-
-               return $wrappedtext;
-       }
-
-       /**
-        * @param array $m
-        *
-        * @return string
-        */
-       public function replaceCallback( $m ) {
-               $marker = Parser::MARKER_PREFIX . "-item-{$this->mMarkerIndex}" . Parser::MARKER_SUFFIX;
-               $this->mMarkerIndex++;
-               $this->mTokens->setPair( $marker, $m[0] );
-               return $marker;
-       }
-
-       /**
-        * @param string $text
-        * @return string
-        */
-       public function postprocess( $text ) {
-               // Revert <html-{link,meta}> back to <{link,meta}>
-               $text = preg_replace( '!<html-(link|meta)([^>]*?)(/{0,1}>)!', '<$1$2$3', $text );
-
-               // Restore the contents of placeholder tokens
-               $text = $this->mTokens->replace( $text );
-
-               return $text;
-       }
-
-}
-
 /**
  * Class to interact with HTML tidy
  *
@@ -113,32 +31,24 @@ class MWTidyWrapper {
  * @ingroup Parser
  */
 class MWTidy {
+       private static $instance;
+
        /**
-        * Interface with html tidy, used if $wgUseTidy = true.
+        * Interface with html tidy.
         * If tidy isn't able to correct the markup, the original will be
         * returned in all its glory with a warning comment appended.
         *
-        * @param string $text Hideous HTML input
+        * @param string $text HTML input fragment. This should not contain a
+        *                     <body> or <html> tag.
         * @return string Corrected HTML output
         */
        public static function tidy( $text ) {
-               $wrapper = new MWTidyWrapper;
-               $wrappedtext = $wrapper->getWrapped( $text );
-
-               $retVal = null;
-               $correctedtext = self::clean( $wrappedtext, false, $retVal );
-
-               if ( $retVal < 0 ) {
-                       wfDebug( "Possible tidy configuration error!\n" );
-                       return $text . "\n<!-- Tidy was unable to run -->\n";
-               } elseif ( is_null( $correctedtext ) ) {
-                       wfDebug( "Tidy error detected!\n" );
-                       return $text . "\n<!-- Tidy found serious XHTML errors -->\n";
+               $driver = self::singleton();
+               if ( !$driver ) {
+                       throw new MWException( __METHOD__.
+                               ': tidy is disabled, caller should have checked MWTidy::isEnabled()' );
                }
-
-               $correctedtext = $wrapper->postprocess( $correctedtext ); // restore any hidden tokens
-
-               return $correctedtext;
+               return $driver->tidy( $text );
        }
 
        /**
@@ -149,170 +59,80 @@ class MWTidy {
         * @return bool Whether the HTML is valid
         */
        public static function checkErrors( $text, &$errorStr = null ) {
-               $retval = 0;
-               $errorStr = self::clean( $text, true, $retval );
-               return ( $retval < 0 && $errorStr == '' ) || $retval == 0;
+               $driver = self::singleton();
+               if ( !$driver ) {
+                       throw new MWException( __METHOD__.
+                               ': tidy is disabled, caller should have checked MWTidy::isEnabled()' );
+               }
+               if ( $driver->supportsValidate() ) {
+                       return $driver->validate( $text, $errorStr );
+               } else {
+                       throw new MWException( __METHOD__ . ": error text return from HHVM tidy is not supported" );
+               }
        }
 
-       /**
-        * Perform a clean/repair operation
-        * @param string $text HTML to check
-        * @param bool $stderr Whether to read result from STDERR rather than STDOUT
-        * @param int &$retval Exit code (-1 on internal error)
-        * @return null|string
-        * @throws MWException
-        */
-       private static function clean( $text, $stderr = false, &$retval = null ) {
-               global $wgTidyInternal;
+       public static function isEnabled() {
+               return self::singleton() !== false;
+       }
 
-               if ( $wgTidyInternal ) {
-                       if ( wfIsHHVM() ) {
-                               if ( $stderr ) {
-                                       throw new MWException( __METHOD__ . ": error text return from HHVM tidy is not supported" );
+       protected static function singleton() {
+               global $wgUseTidy, $wgTidyInternal, $wgTidyConf, $wgDebugTidy, $wgTidyConfig,
+                       $wgTidyBin, $wgTidyOpts;
+
+               if ( self::$instance === null ) {
+                       if ( $wgTidyConfig !== null ) {
+                               $config = $wgTidyConfig;
+                       } elseif ( $wgUseTidy ) {
+                               // b/c configuration
+                               $config = array(
+                                       'tidyConfigFile' => $wgTidyConf,
+                                       'debugComment' => $wgDebugTidy,
+                                       'tidyBin' => $wgTidyBin,
+                                       'tidyCommandLine' => $wgTidyOpts );
+                               if ( $wgTidyInternal ) {
+                                       if ( wfIsHHVM() ) {
+                                               $config['driver'] = 'RaggettInternalHHVM';
+                                       } else {
+                                               $config['driver'] = 'RaggettInternalPHP';
+                                       }
+                               } else {
+                                       $config['driver'] = 'RaggettExternal';
                                }
-                               return self::hhvmClean( $text, $retval );
                        } else {
-                               return self::phpClean( $text, $stderr, $retval );
+                               return false;
                        }
-               } else {
-                       return self::externalClean( $text, $stderr, $retval );
-               }
-       }
-
-       /**
-        * Spawn an external HTML tidy process and get corrected markup back from it.
-        * Also called in OutputHandler.php for full page validation
-        *
-        * @param string $text HTML to check
-        * @param bool $stderr Whether to read result from STDERR rather than STDOUT
-        * @param int &$retval Exit code (-1 on internal error)
-        * @return string|null
-        */
-       private static function externalClean( $text, $stderr = false, &$retval = null ) {
-               global $wgTidyConf, $wgTidyBin, $wgTidyOpts;
-
-               $cleansource = '';
-               $opts = ' -utf8';
-
-               if ( $stderr ) {
-                       $descriptorspec = array(
-                               0 => array( 'pipe', 'r' ),
-                               1 => array( 'file', wfGetNull(), 'a' ),
-                               2 => array( 'pipe', 'w' )
-                       );
-               } else {
-                       $descriptorspec = array(
-                               0 => array( 'pipe', 'r' ),
-                               1 => array( 'pipe', 'w' ),
-                               2 => array( 'file', wfGetNull(), 'a' )
-                       );
-               }
-
-               $readpipe = $stderr ? 2 : 1;
-               $pipes = array();
-
-               $process = proc_open(
-                       "$wgTidyBin -config $wgTidyConf $wgTidyOpts$opts", $descriptorspec, $pipes );
-
-               //NOTE: At least on linux, the process will be created even if tidy is not installed.
-               //      This means that missing tidy will be treated as a validation failure.
-
-               if ( is_resource( $process ) ) {
-                       // Theoretically, this style of communication could cause a deadlock
-                       // here. If the stdout buffer fills up, then writes to stdin could
-                       // block. This doesn't appear to happen with tidy, because tidy only
-                       // writes to stdout after it's finished reading from stdin. Search
-                       // for tidyParseStdin and tidySaveStdout in console/tidy.c
-                       fwrite( $pipes[0], $text );
-                       fclose( $pipes[0] );
-                       while ( !feof( $pipes[$readpipe] ) ) {
-                               $cleansource .= fgets( $pipes[$readpipe], 1024 );
+                       switch ( $config['driver'] ) {
+                               case 'RaggettInternalHHVM':
+                                       self::$instance = new MediaWiki\Tidy\RaggettInternalHHVM( $config );
+                                       break;
+                               case 'RaggettInternalPHP':
+                                       self::$instance = new MediaWiki\Tidy\RaggettInternalPHP( $config );
+                                       break;
+                               case 'RaggettExternal':
+                                       self::$instance = new MediaWiki\Tidy\RaggettExternal( $config );
+                                       break;
+                               case 'Html5Depurate':
+                                       self::$instance = new MediaWiki\Tidy\Html5Depurate( $config );
+                                       break;
+                               default:
+                                       throw new MWException( "Invalid tidy driver: \"{$config['driver']}\"" );
                        }
-                       fclose( $pipes[$readpipe] );
-                       $retval = proc_close( $process );
-               } else {
-                       wfWarn( "Unable to start external tidy process" );
-                       $retval = -1;
                }
-
-               if ( !$stderr && $cleansource == '' && $text != '' ) {
-                       // Some kind of error happened, so we couldn't get the corrected text.
-                       // Just give up; we'll use the source text and append a warning.
-                       $cleansource = null;
-               }
-
-               return $cleansource;
+               return self::$instance;
        }
 
        /**
-        * Use the HTML tidy extension to use the tidy library in-process,
-        * saving the overhead of spawning a new process.
-        *
-        * @param string $text HTML to check
-        * @param bool $stderr Whether to read result from error status instead of output
-        * @param int &$retval Exit code (-1 on internal error)
-        * @return string|null
+        * Set the driver to be used. This is for testing.
+        * @param TidyDriverBase|false|null $instance
         */
-       private static function phpClean( $text, $stderr = false, &$retval = null ) {
-               global $wgTidyConf, $wgDebugTidy;
-
-               if ( ( !wfIsHHVM() && !class_exists( 'tidy' ) ) ||
-                       ( wfIsHHVM() && !function_exists( 'tidy_repair_string' ) )
-               ) {
-                       wfWarn( "Unable to load internal tidy class." );
-                       $retval = -1;
-
-                       return null;
-               }
-
-               $tidy = new tidy;
-               $tidy->parseString( $text, $wgTidyConf, 'utf8' );
-
-               if ( $stderr ) {
-                       $retval = $tidy->getStatus();
-                       return $tidy->errorBuffer;
-               }
-
-               $tidy->cleanRepair();
-               $retval = $tidy->getStatus();
-               if ( $retval == 2 ) {
-                       // 2 is magic number for fatal error
-                       // http://www.php.net/manual/en/function.tidy-get-status.php
-                       $cleansource = null;
-               } else {
-                       $cleansource = tidy_get_output( $tidy );
-                       if ( $wgDebugTidy && $retval > 0 ) {
-                               $cleansource .= "<!--\nTidy reports:\n" .
-                                       str_replace( '-->', '--&gt;', $tidy->errorBuffer ) .
-                                       "\n-->";
-                       }
-               }
-
-               return $cleansource;
+       public static function setInstance( $instance ) {
+               self::$instance = $instance;
        }
 
        /**
-        * Use the tidy extension for HHVM from
-        * https://github.com/wikimedia/mediawiki-php-tidy
-        *
-        * This currently does not support the object-oriented interface, but
-        * tidy_repair_string() can be used for the most common tasks.
-        *
-        * @param string $text HTML to check
-        * @param int &$retval Exit code (-1 on internal error)
-        * @return string|null
+        * Destroy the current singleton instance
         */
-       private static function hhvmClean( $text, &$retval ) {
-               global $wgTidyConf;
-
-               $cleansource = tidy_repair_string( $text, $wgTidyConf, 'utf8' );
-               if ( $cleansource === false ) {
-                       $cleansource = null;
-                       $retval = -1;
-               } else {
-                       $retval = 0;
-               }
-
-               return $cleansource;
+       public static function destroySingleton() {
+               self::$instance = null;
        }
 }
index 664f0a4..677da63 100644 (file)
@@ -1283,8 +1283,6 @@ class Parser {
         * @return string
         */
        private function internalParseHalfParsed( $text, $isMain = true, $linestart = true ) {
-               global $wgUseTidy, $wgAlwaysUseTidy;
-
                $text = $this->mStripState->unstripGeneral( $text );
 
                if ( $isMain ) {
@@ -1335,7 +1333,7 @@ class Parser {
 
                $text = Sanitizer::normalizeCharReferences( $text );
 
-               if ( ( $wgUseTidy && $this->mOptions->getTidy() ) || $wgAlwaysUseTidy ) {
+               if ( MWTidy::isEnabled() && $this->mOptions->getTidy() ) {
                        $text = MWTidy::tidy( $text );
                } else {
                        # attempt to sanitize at least some nesting problems
@@ -3326,7 +3324,8 @@ class Parser {
         */
        public function replaceVariables( $text, $frame = false, $argsOnly = false ) {
                # Is there any text? Also, Prevent too big inclusions!
-               if ( strlen( $text ) < 1 || strlen( $text ) > $this->mOptions->getMaxIncludeSize() ) {
+               $textSize = strlen( $text );
+               if ( $textSize < 1 || $textSize > $this->mOptions->getMaxIncludeSize() ) {
                        return $text;
                }
 
index 3224b13..4a4a828 100644 (file)
@@ -591,10 +591,14 @@ class ResourceLoaderFileModule extends ResourceLoaderModule {
 
                $options = array();
                foreach ( array(
-                       // T104950: Do not include localBasePath or remoteBasePath!
-                       // Those paths may vary over time and needlessly invalidate cache. If the path changes
-                       // in a way that makes relative file paths point to something else, getFileHashes() will
-                       // account for that already.
+                       // The following properties are omitted because they don't affect the module reponse:
+                       // - localBasePath (Per T104950; Changes when absolute directory name changes. If
+                       //    this affects 'scripts' and other file paths, getFileHashes accounts for that.)
+                       // - remoteBasePath (Per T104950)
+                       // - dependencies (provided via startup module)
+                       // - targets
+                       // - group (provided via startup module)
+                       // - position (only used by OutputPage)
                        'scripts',
                        'debugScripts',
                        'loaderScripts',
@@ -602,12 +606,8 @@ class ResourceLoaderFileModule extends ResourceLoaderModule {
                        'languageScripts',
                        'skinScripts',
                        'skinStyles',
-                       'dependencies',
                        'messages',
-                       'targets',
                        'templates',
-                       'group',
-                       'position',
                        'skipFunction',
                        'debugRaw',
                        'raw',
index dc882d4..f474867 100644 (file)
@@ -91,7 +91,7 @@ class LinkSearchPage extends QueryPage {
 
                $request = $this->getRequest();
                $target = $request->getVal( 'target', $par );
-               $namespace = $request->getIntOrNull( 'namespace', null );
+               $namespace = $request->getIntOrNull( 'namespace' );
 
                $protocols_list = array();
                foreach ( $this->getConfig()->get( 'UrlProtocols' ) as $prot ) {
index 9e7dc00..31200c8 100644 (file)
@@ -263,6 +263,8 @@ class UsersPager extends AlphabeticPager {
        function getPageHeader() {
                list( $self ) = explode( '/', $this->getTitle()->getPrefixedDBkey() );
 
+               $this->getOutput()->addModules( 'mediawiki.userSuggest' );
+
                # Form tag
                $out = Xml::openElement(
                        'form',
@@ -271,13 +273,14 @@ class UsersPager extends AlphabeticPager {
                        Xml::fieldset( $this->msg( 'listusers' )->text() ) .
                        Html::hidden( 'title', $self );
 
-               # Username field
+               # Username field (with autocompletion support)
                $out .= Xml::label( $this->msg( 'listusersfrom' )->text(), 'offset' ) . ' ' .
                        Html::input(
                                'username',
                                $this->requestedUser,
                                'text',
                                array(
+                                       'class' => 'mw-autocomplete-user',
                                        'id' => 'offset',
                                        'size' => 20,
                                        'autofocus' => $this->requestedUser === ''
index 26d0fe8..f211ec9 100644 (file)
@@ -113,9 +113,11 @@ class SpecialPagesWithProp extends QueryPage {
                                'pp_value',
                        ),
                        'conds' => array(
-                               'page_id = pp_page',
                                'pp_propname' => $this->propName,
                        ),
+                       'join_conds' => array(
+                               'page' => array( 'INNER JOIN', 'page_id = pp_page' )
+                       ),
                        'options' => array()
                );
        }
index 44be81c..10d55b2 100644 (file)
@@ -359,7 +359,7 @@ class SpecialUpload extends SpecialPage {
                $sessionKey = $this->mUpload->stashSession();
 
                $warningHtml = '<h2>' . $this->msg( 'uploadwarning' )->escaped() . "</h2>\n"
-                       . '<ul class="warning">';
+                       . '<div class="warningbox"><ul>';
                foreach ( $warnings as $warning => $args ) {
                        if ( $warning == 'badfilename' ) {
                                $this->mDesiredDestName = Title::makeTitle( NS_FILE, $args )->getText();
@@ -387,7 +387,7 @@ class SpecialUpload extends SpecialPage {
                        }
                        $warningHtml .= $msg;
                }
-               $warningHtml .= "</ul>\n";
+               $warningHtml .= "</ul></div>\n";
                $warningHtml .= $this->msg( 'uploadwarning-text' )->parseAsBlock();
 
                $form = $this->getUploadForm( $warningHtml, $sessionKey, /* $hideIgnoreWarning */ true );
index 5b6d22b..0410ef0 100644 (file)
@@ -1367,9 +1367,6 @@ class LoginForm extends SpecialPage {
                        'mediawiki.ui.input',
                        'mediawiki.special.userlogin.common.styles'
                ) );
-               $out->addModules( array(
-                       'mediawiki.special.userlogin.common.js'
-               ) );
 
                if ( $this->mType == 'signup' ) {
                        // XXX hack pending RL or JS parse() support for complex content messages
index c17d575..a39690a 100644 (file)
@@ -38,8 +38,6 @@ class UsercreateTemplate extends BaseTemplate {
        }
 
        function execute() {
-               global $wgCookieExpiration;
-               $expirationDays = ceil( $wgCookieExpiration / ( 3600 * 24 ) );
 ?>
 <div class="mw-ui-container">
        <?php if ( $this->haveData( 'languages' ) ) { ?>
diff --git a/includes/tidy.conf b/includes/tidy.conf
deleted file mode 100644 (file)
index 4c4daed..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-# html tidy (http://tidy.sf.net) configuration
-# tidy - validate, correct, and pretty-print HTML files
-# see: man 1 tidy, http://tidy.sourceforge.net/docs/quickref.html
-
-show-body-only: yes
-force-output: yes
-tidy-mark: no
-wrap: 0
-wrap-attributes: no
-literal-attributes: yes
-output-xhtml: yes
-numeric-entities: yes
-enclose-text: yes
-enclose-block-text: yes
-quiet: yes
-quote-nbsp: yes
-fix-backslash: no
-fix-uri: no
-# Don't strip html5 elements we support
-# html-{meta,link} is a hack we use to prevent Tidy from stripping <meta> and <link> used in the body for Microdata
-new-empty-tags: html-meta, html-link, wbr
-new-inline-tags: video, audio, source, track, bdi, data, time, mark
diff --git a/includes/tidy/Html5Depurate.php b/includes/tidy/Html5Depurate.php
new file mode 100644 (file)
index 0000000..23e445f
--- /dev/null
@@ -0,0 +1,45 @@
+<?php
+
+namespace MediaWiki\Tidy;
+use MWHttpRequest;
+use Exception;
+
+class Html5Depurate extends TidyDriverBase {
+       public function __construct( array $config ) {
+               parent::__construct( $config + array(
+                       'url' => 'http://localhost:4339/document',
+                       'timeout' => 10,
+                       'connectTimeout' => 0.5,
+               ) );
+       }
+
+       public function tidy( $text ) {
+               $wrappedtext = '<!DOCTYPE html><html>' .
+                       '<body>' . $text . '</body></html>';
+
+               $req = MWHttpRequest::factory( $this->config['url'],
+                       array(
+                               'method' => 'POST',
+                               'timeout' => $this->config['timeout'],
+                               'connectTimeout' => $this->config['connectTimeout'],
+                               'postData' => array(
+                                       'text' => $wrappedtext
+                               )
+                       ) );
+               $status = $req->execute();
+               if ( !$status->isOK() ) {
+                       throw new Exception( "Error contacting depurate service: " . $status->getWikiText() );
+               } elseif ( $req->getStatus() !== 200 ) {
+                       throw new Exception( "Depurate returned error: " . $status->getWikiText() );
+               }
+               $result = $req->getContent();
+               $startBody = strpos( $result, "<body>" );
+               $endBody = strrpos( $result, "</body>" );
+               if ( $startBody !== false && $endBody !== false && $endBody > $startBody ) {
+                       $startBody += strlen( "<body>" );
+                       return substr( $result, $startBody, $endBody - $startBody );
+               } else {
+                       return $text . "\n<!-- Html5Depurate returned an invalid result -->";
+               }
+       }
+}
diff --git a/includes/tidy/RaggettBase.php b/includes/tidy/RaggettBase.php
new file mode 100644 (file)
index 0000000..a3717b2
--- /dev/null
@@ -0,0 +1,47 @@
+<?php
+
+namespace MediaWiki\Tidy;
+
+abstract class RaggettBase extends TidyDriverBase {
+       /**
+        * Generic interface for wrapping and unwrapping HTML for Dave Raggett's tidy.
+        *
+        * @param string $text Hideous HTML input
+        * @return string Corrected HTML output
+        */
+       public function tidy( $text ) {
+               $wrapper = new RaggettWrapper;
+               $wrappedtext = $wrapper->getWrapped( $text );
+
+               $retVal = null;
+               $correctedtext = $this->cleanWrapped( $wrappedtext, false, $retVal );
+
+               if ( $retVal < 0 ) {
+                       wfDebug( "Possible tidy configuration error!\n" );
+                       return $text . "\n<!-- Tidy was unable to run -->\n";
+               } elseif ( is_null( $correctedtext ) ) {
+                       wfDebug( "Tidy error detected!\n" );
+                       return $text . "\n<!-- Tidy found serious XHTML errors -->\n";
+               }
+
+               $correctedtext = $wrapper->postprocess( $correctedtext ); // restore any hidden tokens
+
+               return $correctedtext;
+       }
+
+       public function validate( $text, &$errorStr ) {
+               $retval = 0;
+               $errorStr = $this->cleanWrapped( $text, true, $retval );
+               return ( $retval < 0 && $errorStr == '' ) || $retval == 0;
+       }
+
+       /**
+        * Perform a clean/repair operation
+        * @param string $text HTML to check
+        * @param bool $stderr Whether to read result from STDERR rather than STDOUT
+        * @param int &$retval Exit code (-1 on internal error)
+        * @return null|string
+        * @throws MWException
+        */
+       abstract protected function cleanWrapped( $text, $stderr = false, &$retval = null );
+}
diff --git a/includes/tidy/RaggettExternal.php b/includes/tidy/RaggettExternal.php
new file mode 100644 (file)
index 0000000..1193318
--- /dev/null
@@ -0,0 +1,73 @@
+<?php
+
+namespace MediaWiki\Tidy;
+
+class RaggettExternal extends RaggettBase {
+       /**
+        * Spawn an external HTML tidy process and get corrected markup back from it.
+        * Also called in OutputHandler.php for full page validation
+        *
+        * @param string $text HTML to check
+        * @param bool $stderr Whether to read result from STDERR rather than STDOUT
+        * @param int &$retval Exit code (-1 on internal error)
+        * @return string|null
+        */
+       protected function cleanWrapped( $text, $stderr = false, &$retval = null ) {
+               $cleansource = '';
+               $opts = ' -utf8';
+
+               if ( $stderr ) {
+                       $descriptorspec = array(
+                               0 => array( 'pipe', 'r' ),
+                               1 => array( 'file', wfGetNull(), 'a' ),
+                               2 => array( 'pipe', 'w' )
+                       );
+               } else {
+                       $descriptorspec = array(
+                               0 => array( 'pipe', 'r' ),
+                               1 => array( 'pipe', 'w' ),
+                               2 => array( 'file', wfGetNull(), 'a' )
+                       );
+               }
+
+               $readpipe = $stderr ? 2 : 1;
+               $pipes = array();
+
+               $process = proc_open(
+                       "{$this->config['tidyBin']} -config {$this->config['tidyConfigFile']} " .
+                       $this->config['tidyCommandLine'] . $opts, $descriptorspec, $pipes );
+
+               //NOTE: At least on linux, the process will be created even if tidy is not installed.
+               //      This means that missing tidy will be treated as a validation failure.
+
+               if ( is_resource( $process ) ) {
+                       // Theoretically, this style of communication could cause a deadlock
+                       // here. If the stdout buffer fills up, then writes to stdin could
+                       // block. This doesn't appear to happen with tidy, because tidy only
+                       // writes to stdout after it's finished reading from stdin. Search
+                       // for tidyParseStdin and tidySaveStdout in console/tidy.c
+                       fwrite( $pipes[0], $text );
+                       fclose( $pipes[0] );
+                       while ( !feof( $pipes[$readpipe] ) ) {
+                               $cleansource .= fgets( $pipes[$readpipe], 1024 );
+                       }
+                       fclose( $pipes[$readpipe] );
+                       $retval = proc_close( $process );
+               } else {
+                       wfWarn( "Unable to start external tidy process" );
+                       $retval = -1;
+               }
+
+               if ( !$stderr && $cleansource == '' && $text != '' ) {
+                       // Some kind of error happened, so we couldn't get the corrected text.
+                       // Just give up; we'll use the source text and append a warning.
+                       $cleansource = null;
+               }
+
+               return $cleansource;
+       }
+
+       public function supportsValidate() {
+               return true;
+       }
+}
diff --git a/includes/tidy/RaggettInternalHHVM.php b/includes/tidy/RaggettInternalHHVM.php
new file mode 100644 (file)
index 0000000..2a3986d
--- /dev/null
@@ -0,0 +1,29 @@
+<?php
+
+namespace MediaWiki\Tidy;
+
+class RaggettInternalHHVM extends RaggettBase {
+       /**
+        * Use the HTML tidy extension to use the tidy library in-process,
+        * saving the overhead of spawning a new process.
+        *
+        * @param string $text HTML to check
+        * @param bool $stderr Whether to read result from error status instead of output
+        * @param int &$retval Exit code (-1 on internal error)
+        * @return string|null
+        */
+       protected function cleanWrapped( $text, $stderr = false, &$retval = null ) {
+               if ( $stderr ) {
+                       throw new Exception( "\$stderr cannot be used with RaggettInternalHHVM" );
+               }
+               $cleansource = tidy_repair_string( $text, $this->config['tidyConfigFile'], 'utf8' );
+               if ( $cleansource === false ) {
+                       $cleansource = null;
+                       $retval = -1;
+               } else {
+                       $retval = 0;
+               }
+
+               return $cleansource;
+       }
+}
diff --git a/includes/tidy/RaggettInternalPHP.php b/includes/tidy/RaggettInternalPHP.php
new file mode 100644 (file)
index 0000000..1ce14b6
--- /dev/null
@@ -0,0 +1,52 @@
+<?php
+
+namespace MediaWiki\Tidy;
+
+class RaggettInternalPHP extends RaggettBase {
+       /**
+        * Use the HTML tidy extension to use the tidy library in-process,
+        * saving the overhead of spawning a new process.
+        *
+        * @param string $text HTML to check
+        * @param bool $stderr Whether to read result from error status instead of output
+        * @param int &$retval Exit code (-1 on internal error)
+        * @return string|null
+        */
+       protected function cleanWrapped( $text, $stderr = false, &$retval = null ) {
+               if ( !class_exists( 'tidy' ) ) {
+                       wfWarn( "Unable to load internal tidy class." );
+                       $retval = -1;
+
+                       return null;
+               }
+
+               $tidy = new \tidy;
+               $tidy->parseString( $text, $this->config['tidyConfigFile'], 'utf8' );
+
+               if ( $stderr ) {
+                       $retval = $tidy->getStatus();
+                       return $tidy->errorBuffer;
+               }
+
+               $tidy->cleanRepair();
+               $retval = $tidy->getStatus();
+               if ( $retval == 2 ) {
+                       // 2 is magic number for fatal error
+                       // http://www.php.net/manual/en/function.tidy-get-status.php
+                       $cleansource = null;
+               } else {
+                       $cleansource = tidy_get_output( $tidy );
+                       if ( !empty( $this->config['debugComment'] ) && $retval > 0 ) {
+                               $cleansource .= "<!--\nTidy reports:\n" .
+                                       str_replace( '-->', '--&gt;', $tidy->errorBuffer ) .
+                                       "\n-->";
+                       }
+               }
+
+               return $cleansource;
+       }
+
+       public function supportsValidate() {
+               return true;
+       }
+}
diff --git a/includes/tidy/RaggettWrapper.php b/includes/tidy/RaggettWrapper.php
new file mode 100644 (file)
index 0000000..083f402
--- /dev/null
@@ -0,0 +1,89 @@
+<?php
+namespace MediaWiki\Tidy;
+
+use ReplacementArray;
+use ParserOutput;
+use Parser;
+
+/**
+ * Class used to hide mw:editsection tokens from Tidy so that it doesn't break them
+ * or break on them. This is a bit of a hack for now, but hopefully in the future
+ * we may create a real postprocessor or something that will replace this.
+ * It's called wrapper because for now it basically takes over MWTidy::tidy's task
+ * of wrapping the text in a xhtml block
+ *
+ * This re-uses some of the parser's UNIQ tricks, though some of it is private so it's
+ * duplicated. Perhaps we should create an abstract marker hiding class.
+ *
+ * @ingroup Parser
+ */
+class RaggettWrapper {
+
+       /**
+        * @var ReplacementArray
+        */
+       protected $mTokens;
+
+       protected $mMarkerIndex;
+
+       public function __construct() {
+               $this->mTokens = null;
+       }
+
+       /**
+        * @param string $text
+        * @return string
+        */
+       public function getWrapped( $text ) {
+               $this->mTokens = new ReplacementArray;
+               $this->mMarkerIndex = 0;
+
+               // Replace <mw:editsection> elements with placeholders
+               $wrappedtext = preg_replace_callback( ParserOutput::EDITSECTION_REGEX,
+                       array( &$this, 'replaceCallback' ), $text );
+               // ...and <mw:toc> markers
+               $wrappedtext = preg_replace_callback( '/\<\\/?mw:toc\>/',
+                       array( &$this, 'replaceCallback' ), $wrappedtext );
+               // ... and <math> tags
+               $wrappedtext = preg_replace_callback( '/\<math(.*?)\<\\/math\>/s',
+                       array( &$this, 'replaceCallback' ), $wrappedtext );
+               // Modify inline Microdata <link> and <meta> elements so they say <html-link> and <html-meta> so
+               // we can trick Tidy into not stripping them out by including them in tidy's new-empty-tags config
+               $wrappedtext = preg_replace( '!<(link|meta)([^>]*?)(/{0,1}>)!', '<html-$1$2$3', $wrappedtext );
+
+               // Wrap the whole thing in a doctype and body for Tidy.
+               $wrappedtext = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"' .
+                       ' "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html>' .
+                       '<head><title>test</title></head><body>' . $wrappedtext . '</body></html>';
+
+               return $wrappedtext;
+       }
+
+       /**
+        * @param array $m
+        *
+        * @return string
+        */
+       public function replaceCallback( $m ) {
+               $marker = Parser::MARKER_PREFIX . "-item-{$this->mMarkerIndex}" . Parser::MARKER_SUFFIX;
+               $this->mMarkerIndex++;
+               $this->mTokens->setPair( $marker, $m[0] );
+               return $marker;
+       }
+
+       /**
+        * @param string $text
+        * @return string
+        */
+       public function postprocess( $text ) {
+               // Revert <html-{link,meta}> back to <{link,meta}>
+               $text = preg_replace( '!<html-(link|meta)([^>]*?)(/{0,1}>)!', '<$1$2$3', $text );
+
+               // Restore the contents of placeholder tokens
+               $text = $this->mTokens->replace( $text );
+
+               return $text;
+       }
+
+}
+?>
diff --git a/includes/tidy/TidyDriverBase.php b/includes/tidy/TidyDriverBase.php
new file mode 100644 (file)
index 0000000..1d994aa
--- /dev/null
@@ -0,0 +1,40 @@
+<?php
+
+namespace MediaWiki\Tidy;
+
+/**
+ * Base class for HTML cleanup utilities
+ */
+abstract class TidyDriverBase {
+       protected $config;
+
+       function __construct( $config ) {
+               $this->config = $config;
+       }
+
+       /**
+        * Return true if validate() can be used
+        */
+       public function supportsValidate() {
+               return false;
+       }
+
+       /**
+        * Check HTML for errors, used if $wgValidateAllHtml = true.
+        *
+        * @param string $text
+        * @param string &$errorStr Return the error string
+        * @return bool Whether the HTML is valid
+        */
+       public function validate( $text, &$errorStr ) {
+               throw new MWException( get_class( $this ) . " does not support validate()" );
+       }
+
+       /**
+        * Clean up HTML
+        *
+        * @param string HTML document fragment to clean up
+        * @param string The corrected HTML output
+        */
+       public abstract function tidy( $text );
+}
diff --git a/includes/tidy/tidy.conf b/includes/tidy/tidy.conf
new file mode 100644 (file)
index 0000000..4c4daed
--- /dev/null
@@ -0,0 +1,22 @@
+# html tidy (http://tidy.sf.net) configuration
+# tidy - validate, correct, and pretty-print HTML files
+# see: man 1 tidy, http://tidy.sourceforge.net/docs/quickref.html
+
+show-body-only: yes
+force-output: yes
+tidy-mark: no
+wrap: 0
+wrap-attributes: no
+literal-attributes: yes
+output-xhtml: yes
+numeric-entities: yes
+enclose-text: yes
+enclose-block-text: yes
+quiet: yes
+quote-nbsp: yes
+fix-backslash: no
+fix-uri: no
+# Don't strip html5 elements we support
+# html-{meta,link} is a hack we use to prevent Tidy from stripping <meta> and <link> used in the body for Microdata
+new-empty-tags: html-meta, html-link, wbr
+new-inline-tags: video, audio, source, track, bdi, data, time, mark
index 288a311..c1b5020 100644 (file)
@@ -37,11 +37,11 @@ abstract class IteratorDecorator implements Iterator {
        }
 
        public function next() {
-               return $this->iterator->next();
+               $this->iterator->next();
        }
 
        public function rewind() {
-               return $this->iterator->rewind();
+               $this->iterator->rewind();
        }
 
        public function valid() {
index 8cf83e5..09b45c5 100644 (file)
        "cannotdelete": "НэкIубгъоу е файлэу \"$1\" тегъэкIын лъэкIыгъэп.\nПэмыкI нэбгырэм тыригъэкIыгъахэн фае.",
        "cannotdelete-title": "НэкIубгъоу \"$1\" тегъэкIыгъэн лъэкIырэп",
        "badtitle": "ЦӀэ дэгъуэп",
+       "badtitletext": "УзкIэупчIэрэ нэкIубгъом ыцIэр къуанчэ, е нэкIы, е бзэзэпыщэ е интервики гъэнэфагъэп.\nМыхъущт символ агъэфедагъэнкIи мэхъу.",
        "viewsource": "Еплъ лъапсэм",
        "viewsource-title": "Еплъ лъапсэм $1 пае",
        "protectedpagetext": "ЕIэзэнхэм ыкIи нэмыкI шIэнмэ яягъэ къэмыкIынэу мы нэкIубгъор ухъумагъэу щыт.",
        "loginreqlink": "системэм хахь",
        "accmailtitle": "ШъэфгущыIэр агъэхьыгъ",
        "newarticle": "(КIэ)",
+       "newarticletext": "ЩымыIэ нэкIубгъом уекIугъ зэпыщэмкIэ.\nНэкIубгъор ебгъэжьэным пае ычIэгъ щыт плIэмыем зыгорэ итх (еплъ [$1 IэпыIэгъу нэкIубгъом] нахьыбэу пшIэным пае).\nУмышIахэу мыщ укъэкIуагъэмэ, уи броузерым и <strong>зэкIакIо</strong> кнопкэм теIункI.",
        "noarticletext": "Текст пари итыгоп мы нэкIубгъом.\n[[Special:Search/{{PAGENAME}}|Мы нэкIубгъом ыцIэ улъыхъун]] плъэкIыщт нэмыкI нэкIубгъомэ,\n<span class=\"plainlinks\">[{{fullurl:{{#Special:Log}}|page={{FULLPAGENAMEE}}}} ехьылIэгъэ журналхэм къащыбгъотын],\nе [{{fullurl:{{FULLPAGENAME}}|action=edit}} мы нэкIубгъом уеIэзэн]</span>.",
        "noarticletext-nopermission": "Текст пари итыгоп мы нэкIубгъом.\n[[Special:Search/{{PAGENAME}}|Мы нэкIубгъом ыцIэ улъыхъун]] плъэкIыщт нэмыкI нэкIубгъомэ, е\n<span class=\"plainlinks\">[{{fullurl:{{#Special:Log}}|page={{FULLPAGENAMEE}}}} ехьылIэгъэ журналхэм къащыбгъотын]</span>. Ау мы нэкIубгъор уублэнэу фитыныгъэ уиIэп.",
        "userpage-userdoesnotexist-view": "Аккаунтэу \"$1\" регистрацие ыкIугъэп.",
        "compareselectedversions": "Хэгъэщыгъэ версиехэр зэгъапш",
        "editundo": "зэкӀэгъэкӀожь",
        "diff-empty": "(зэфэмыдэ яIэп)",
+       "diff-multi-sameuser": "({{PLURAL:$1|Зы гурыт версие горэ|$1 гурыт версиехэр}} зы нэбгырэм иеу къэгъэлъэгъуагъэп)",
        "searchresults": "Къэгъотынэу хъугъэр",
        "searchresults-title": "$1-м пае къэгъот",
        "prevn": "ыпэ {{PLURAL:$1|$1}}",
        "whatlinkshere-next": "{{PLURAL:$1|кӀэлъыкӀорэр|кӀэлъыкӀорэ $1}}",
        "whatlinkshere-links": "← зэпыщэхэр",
        "whatlinkshere-hideredirs": "$1 гъэкӀожьын",
+       "whatlinkshere-hidetrans": "$1 хэлъхьаныгъэ",
        "whatlinkshere-hidelinks": "$1 зэпыщ",
        "whatlinkshere-filters": "Филтрэхэр",
        "ipaddressorusername": "IP-адрес е нэбгырацIэ:",
        "tooltip-t-permalink": "Мы нэкӀубгъом къакIорэ зэмыхъокӀ зэпыщ",
        "tooltip-ca-nstab-main": "КӀоцӀытхагъэм еплъ",
        "tooltip-ca-nstab-user": "ЦӀыфым итхьапэ еплъ",
-       "tooltip-ca-nstab-special": "Мы нэкӀубгъор шъхьафы, зыцэ хэптхэжьынэу щытэп",
+       "tooltip-ca-nstab-special": "Мы нэкӀубгъор шъхьафы, зыцэ хэптхэжьын хъущтэп",
        "tooltip-ca-nstab-project": "Проектым и нэкӀубгъу",
        "tooltip-ca-nstab-image": "Тхьапэм и файл еплъ",
        "tooltip-ca-nstab-mediawiki": "Систем мессаджым еплъ",
        "previousdiff": "← ЫпэкъэкӀорэ еӀэзэн",
        "nextdiff": "Нахь еӀэзэныгъакӀ →",
        "file-info-size": "Пиксел $1 × $2, файлым иинагъэ: $3, MIME-тип: $4",
+       "file-nohires": "Нахь зэхэщыкIэ ин щыIэп.",
        "svg-long-desc": "SVG файл, номиналэу $1 × $2 пиксел, файлым иинагъэ: $3",
        "show-big-image": "Оригинал файлыр",
        "show-big-image-preview": "Мыщ и ыпэтеплъэм иинагъэр: $1.",
        "exif-orientation-1": "Тэрэз",
        "namespacesall": "зэкӀэ",
        "monthsall": "зэкӀэ",
+       "signature": "[[{{ns:user}}:$1|$2]] ([[{{ns:user_talk}}:$1|тегущыIэныр]])",
        "fileduplicatesearch-submit": "Лъыхъу",
        "specialpages": "ЯӀамышӀыкӀ нэкӀубгъохэр",
        "specialpages-group-login": "Къыхахь / аккаунт къэубл",
index 734acc3..2332ff6 100644 (file)
        "title-invalid-interwiki": "عنوان الصفحة المطلوب يتضمن وصلة لحلقة لغة وهو ما لا يمكن استخدامه في العناوين.",
        "title-invalid-talk-namespace": "عنوان الصفحة المطلوبة يشير إلى صفحة نقاش غير موجودة.",
        "title-invalid-characters": "عنوان الصفحة المطلوب يتضمن محارف غير صالحة: \"$1\"",
+       "title-invalid-leading-colon": "عنوان الصفحة المطلوب يتضمن فاصلة غير صالحة في بدايته.",
        "perfcached": "البيانات التالية مخبأة و قد لا تكون محدثة. {{PLURAL:$1||نتيجة واحدة|نتيجتان|$1 نتائج|$1 نتيجة}} على الأكثر {{PLURAL:$1||مخبّأة|مخبّأتان|مخبّأة}}.",
        "perfcachedts": "البيانات التالية مخزنة، وكان آخر تحديث لها في $1. العدد الأقصى للنتائج المخزنة هو {{PLURAL:$4||نتيجة واحدة|نتيجتان|$4 نتائج|$4 نتيجة}}.",
        "querypage-no-updates": "تحديثات هذه الصفحة معطلة حاليا.\nالبيانات هنا لن يتم تحديثها حاليا.",
        "createacct-benefit-body2": "{{PLURAL:$1|صفحة}}",
        "createacct-benefit-body3": "آخر {{PLURAL:$1|مساهم|مساهمين}}",
        "badretype": "كلمات السر التي أدخلتها لا تتطابق.",
+       "usernameinprogress": "إن عملية إنشاء حساب لاسم المستخدم هذا جارية بالفعل. برجاء الانتظار.",
        "userexists": "اسم المستخدم الذي تم إدخاله مستعمل بالفعل.\nالرجاء اختيار اسم مختلف.",
        "loginerror": "خطأ في الدخول",
        "createacct-error": "خطأ في إنشاء حساب",
index 164c056..301dcc8 100644 (file)
        "yourpassword": "الباسوورد:",
        "userlogin-yourpassword": "الباسورد:",
        "yourpasswordagain": "اكتب الباسورد تاني:",
+       "createacct-yourpasswordagain": "أكد كلمه السر",
        "remembermypassword": " (لمدة   $1 {{PLURAL:$1|يوم|يوم}})خليك فاكر دخولى على الكمبيوتر دا",
        "yourdomainname": "النطاق بتاعك:",
        "externaldberror": "يا إما فى حاجة غلط فى الدخول على قاعدة البيانات الخارجية أو انت مش مسموح لك تعمل تحديث لحسابك الخارجي.",
        "file-nohires": "مافيش  ريزوليوشن اعلى متوفر.",
        "svg-long-desc": "ملف SVG، اساسا $1 × $2 بكسل، حجم الملف: $3",
        "show-big-image": "الصوره الاصليه",
+       "show-big-image-other": "{{PLURAL:$2||البعد التانى|البعدان التانيين|الأبعاد التانيه}}: $1.",
        "show-big-image-size": "$1 × $2 بكسل",
        "file-info-gif-looped": "ملفوف",
        "file-info-gif-frames": "$1 {{PLURAL:$1|برواز|براويز}}",
        "logentry-delete-delete": "{{GENDER:$2|مسح|مسحت}} $1 صفحة $3",
        "revdelete-restricted": "طبق التعليمات على السيسوبات",
        "revdelete-unrestricted": "شيل الضوابط من على السيسوبات",
+       "logentry-newusers-create": "تم فتح حساب {{GENDER:$2|اليوزر|اليوزره}} $1",
        "logentry-upload-upload": " {{GENDER:$2|رفع|اترفعت}} $1 $3",
        "rightsnone": "(فاضى)",
        "revdelete-summary": "ملخص التعديل",
index cf9d6dd..a5b4d78 100644 (file)
@@ -16,7 +16,8 @@
                        "Baloch Afghanistan",
                        "Macofe",
                        "Sadiqr",
-                       "Mjbmr"
+                       "Mjbmr",
+                       "Alp Er Tunqa"
                ]
        },
        "tog-underline": "باغلانتی‌لارین آلتینی خطله:",
@@ -88,7 +89,7 @@
        "june": "ژوئن",
        "july": "ژولای",
        "august": "آقوست",
-       "september": "سئپتامبر",
+       "september": "سپتامبر",
        "october": "اوْکتوبر",
        "november": "نوْوامبر",
        "december": "دئسامبر",
        "june-gen": "ژوئن",
        "july-gen": "جولای",
        "august-gen": "آقوست",
-       "september-gen": "سئپتامبر",
+       "september-gen": "سپتامبر",
        "october-gen": "اوکتوبر",
        "november-gen": "نووامبر",
        "december-gen": "دئسامبر",
        "jun": "ژوئن",
        "jul": "ژولای",
        "aug": "آقوست",
-       "sep": "سئپتامبر",
+       "sep": "سپتامبر",
        "oct": "اوْکتوبر",
        "nov": "نوْوامبر",
        "dec": "دئسامبر",
        "welcomecreation-msg": "حسابینیز آچیلدی.\n[[Special:Preferences|{{SITENAME}}ترجیحلر]] دییشدیرمیی اونوتمایین.",
        "yourname": "ایستیفاده‌چی آدی:",
        "userlogin-yourname": "ایشلدن آدی",
-       "userlogin-yourname-ph": "اÛ\8cستÛ\8cÙ\81ادÙ\87â\80\8cÚ\86Û\8c آدینیزی دَییشدیرین",
-       "createacct-another-username-ph": "اÛ\8cستÛ\8cÙ\81ادÙ\87â\80\8cÚ\86Û\8c Ø¢Ø¯Û\8cÙ\86Û\8cزÛ\8c Ø¯Ø§Ø®Û\8cÙ\84 Ø§Ø¦Ø¯ین",
+       "userlogin-yourname-ph": "اÛ\8cØ´Ù\84دÙ\86 آدینیزی دَییشدیرین",
+       "createacct-another-username-ph": "اÛ\8cØ´Ù\84دÙ\86 Ø¢Ø¯Û\8cÙ\86Û\8cزÛ\8c Ú¯Û\8cردÛ\8cرین",
        "yourpassword": "رمز:",
        "userlogin-yourpassword": "رمز",
-       "userlogin-yourpassword-ph": "رمزینیزی داخیل ائدین",
-       "createacct-yourpassword-ph": "بیر رمز داخیل ائدین",
+       "userlogin-yourpassword-ph": "رمزینیزی گیردیرن",
+       "createacct-yourpassword-ph": "بیر رمز گیردیرین",
        "yourpasswordagain": "رمزی یئنی‌دن یازین:",
        "createacct-yourpasswordagain": "رمزی دوغرولایین",
-       "createacct-yourpasswordagain-ph": "رمزی یئنی‌دن داخیل ائدین",
+       "createacct-yourpasswordagain-ph": "رمزی یئنی‌دن گیردیرن",
        "remembermypassword": "بو بیلگی‌سایاردا منیم گیریشیمی (چوخو $1 {{PLURAL:$1|گون}}ه قدر) یاددا ساخلا",
        "userlogin-remembermypassword": "منی ایچری‌ده ساخلا",
        "userlogin-signwithsecure": "آرخایین باغلانتی ایشلدین",
        "gotaccountlink": "گیریش",
        "userlogin-resetlink": "گیریش بیلگیلرینیزی اونوتموسونوز؟",
        "userlogin-resetpassword-link": "رمزینیزی اونوتموسوز مو؟",
-       "userlogin-helplink2": "یاردیم ایله گیریش",
+       "userlogin-helplink2": "کؤمک ایله گیریش",
        "userlogin-loggedin": "سیر حال حاضیردا {{GENDER:$1|$1}} عونوانیندا گیریش ائدیب سیز.\nآشاغیداکی فورمودان بیر آیری ایشلدن عونوانیندا گیریش اوچون ایشلدین.",
        "userlogin-createanother": "بیر باشقا حساب یارات",
        "createacct-emailrequired": "ایمیل آدرسی",
        "createacct-emailoptional": "ایمیل آدرسی (ایستگه باغلی)",
-       "createacct-email-ph": "ایمیل آدرسینیزی داخیل ائدین",
-       "createacct-another-email-ph": "ایمیل آدرسینیزی داخیل ائدین",
+       "createacct-email-ph": "ایمیل آدرسینیزی گیردیرن",
+       "createacct-another-email-ph": "ایمیل آدرسینیزی گیردیرن",
        "createaccountmail": "بیر گئچیجی راست‌گله رمز ایشلت و اونو آشاغیدا بللندیرن ایمیل آدرسینه گؤندر",
        "createacct-realname": "دوغرو آد (ایستگه باغلی)",
        "createaccountreason": "نَدَن‌لیک:",
        "createacct-reason": "سبب",
        "createacct-reason-ph": "ندن سیز باشقا حساب یارادیرسینیز",
        "createacct-captcha": "امنیت یوخلاماسی",
-       "createacct-imgcaptcha-ph": "اوست‌ده‌کی گؤردوگونوز یازی‌نی داخیل ائدین",
+       "createacct-imgcaptcha-ph": "اوست‌ده‌کی گؤردوگونوز یازی‌نی گیردیرن",
        "createacct-submit": "حسابینیزی یارادین",
        "createacct-another-submit": "بیر باشقا حساب یارات",
        "createacct-benefit-heading": "{{SITENAME}} سیزین کیمی آدام‌لارین الی ایله یارانیب‌دیر.",
        "createacct-benefit-body1": "{{PLURAL:$1|دَییشیکلیک}}",
-       "createacct-benefit-body2": "{{PLURAL:$1|صحیفه}}",
+       "createacct-benefit-body2": "{{PLURAL:$1|صفحه}}",
        "createacct-benefit-body3": "سون {{PLURAL:$1|قاتیلان|قاتیلانلار}}",
        "badretype": "یازدیغینیز رمزلر بیر دئییل‌لر.",
        "userexists": "یازدیغینیز آد، اؤنجه‌دن ایشده‌دیر.\nلوطفاً باشقا بیر آد سئچین.",
        "prefs-advancedrendering": "گلیشمیش سئچَنکلر",
        "prefs-advancedsearchoptions": "گلیشمیش سئچَنکلر",
        "prefs-advancedwatchlist": "گلیشمیش سئچَنکلر",
-       "prefs-displayrc": "گؤرونتو سئچَنکلری",
-       "prefs-displaywatchlist": "گؤرونتو سئچَنکلری",
+       "prefs-displayrc": "عکس سئچَنکلری",
+       "prefs-displaywatchlist": "عکس سئچَنکلری",
        "prefs-tokenwatchlist": "آدرس",
        "prefs-diffs": "فرق‌لر",
        "prefs-help-prefershttps": "سیزین بو ترجیحینیزین اثری سیزین سونراکی گیریشینیز دن سونرا اولاجاق.",
        "recentchanges-label-minor": "بو بیر کیچیک دَییشدیرمه‌دیر",
        "recentchanges-label-bot": "بو دییشیک بیر بوت طرفیندن ائدیلیب‌دیر",
        "recentchanges-label-unpatrolled": "بو دییشیکلیک هله گؤزدن گئچیریلمه‌ییب‌دیر",
-       "recentchanges-label-plusminus": "صحیفه‌نین اؤلچوسو بایت میقداری ایله تعیین ائدیلیر",
-       "recentchanges-legend-heading": "'''ایختیصارلار:'''",
-       "recentchanges-legend-newpage": "{{int:recentchanges-label-newpage}} (هم‌ده [[Special:NewPages|یئنی صحیفه‌لرین لیستینه]] باخین)",
+       "recentchanges-label-plusminus": "صفحه‌نین اؤلچوسو بایت میقداری ایله تعیین ائدیلیر",
+       "recentchanges-legend-heading": "'''قیسالتمالار:'''",
+       "recentchanges-legend-newpage": "{{int:recentchanges-label-newpage}} (بیرده [[Special:NewPages|یئنی صفحه‌لرین لیستینه]] باخین)",
        "rcnotefrom": "آشاغی داکی دَییشیک لرده <strong>$3, $4</strong> (دن <strong>$1</strong> {{PLURAL:$5|چان گوستریلیب|چان گوستریلیب دیر}}).",
        "rclistfrom": "$3 $2 واختیندان باشلایاراق یئنی دییشیکلری گؤستر",
        "rcshowhideminor": "کیچیک دَییشیکلری $1",
        "rcshowhidebots": "بوتلاری $1",
        "rcshowhidebots-show": "گؤستر",
        "rcshowhidebots-hide": "گیزلت",
-       "rcshowhideliu": "Û\8cازÛ\8cÙ\84Ù\85Û\8cØ´ Ø§Û\8cستÙ\81ادÙ\87â\80\8cÚ\86Û\8cÙ\84رÛ\8c $1",
+       "rcshowhideliu": "Û\8cازÛ\8cÙ\84Ù\85Û\8cØ´ Ø§Û\8cØ´Ù\84دÙ\86â\80\8cÙ\84رÛ\8c $1",
        "rcshowhideliu-show": "گؤستر",
        "rcshowhideliu-hide": "گیزلت",
-       "rcshowhideanons": "تاÙ\86Û\8cÙ\86Ù\85اÙ\85Û\8cØ´ Ø§Û\8cستÛ\8cÙ\81ادÙ\87â\80\8cÚ\86Û\8cÙ\84رÛ\8c $1",
+       "rcshowhideanons": "تاÙ\86Û\8cÙ\86Ù\85اÙ\85Û\8cØ´ Ø§Û\8cØ´Ù\84دÙ\86â\80\8cÙ\84رÛ\8c $1",
        "rcshowhideanons-show": "گؤستر",
        "rcshowhideanons-hide": "گیزلت",
        "rcshowhidepatr": "نظارت ائدیلن دَییشیکلیکلری $1",
        "activeusers-intro": "بوردا سون {{PLURAL:$1|بیر|$1}} گون‌ده بیر ایشلر گؤرن ایستیفاده‌چیلرین لیستی گؤستریلیر.",
        "activeusers-count": "سون {{PLURAL:$3|گون|$3 گون}}‌ده، {{PLURAL:$1|$1}} چالیشما",
        "activeusers-from": "بوندان باشلایاراق ایستیفاده‌چیلری گؤستر:",
-       "activeusers-hidebots": "بÙ\88تلاری گیزلت",
+       "activeusers-hidebots": "رÙ\88Ù\92باتâ\80\8cلاری گیزلت",
        "activeusers-hidesysops": "ایداره‌چیلری گیزلت",
        "activeusers-noresult": "هئچ ایشلدن تاپیلمادی.",
        "listgrouprights": "ایستیفاده‌چی قروپ حاقلاری",
        "notvisiblerev": "باشقا ایستیفادی‌چی‌نین سون دییشیک‌لیگی سیلینیب",
        "watchlist-details": "دانیشیق صفحه‌لرینی آیری سایمایاراق، {{PLURAL:$1|$1 صفحه‌نی}} ایزله‌ییرسینیز.",
        "wlheader-enotif": "ایمیل ایله بیلدیریش آچیلیب‌دیر.",
-       "wlheader-showupdated": "سÙ\88Ù\86 Ú¯Ø¤Ø±Ù\88Ø´Ù\88Ù\86Ù\88زدÙ\86 Ø³Ù\88Ù\86را Ø§Ø¦Ø¯Û\8cÙ\84Ù\86 Ø¯Û\8cÛ\8cØ´Û\8cÚ©Ù\84Û\8cÚ©Ù\84ر '''Ù\82اÙ\84Û\8cÙ\86''' Ú¯Ø¤Ø³ØªØ±Û\8cÙ\84Û\8cبدÛ\8cÙ\84ر.",
+       "wlheader-showupdated": "سÙ\88Ù\86 Ú¯Ø¤Ø±Ù\88Ø´Ù\88Ù\86Ù\88زدÙ\86 Ø³Ù\88Ù\92Ù\86را Ø§Ø¦Ø¯Û\8cÙ\84Ù\86 Ø¯Û\8cÛ\8cØ´Û\8cÚ©Ù\84Û\8cÚ©Ù\84ر '''Ù\82اÙ\84Û\8cÙ\86''' Ú¯Ø¤Ø±Ø³Ø¯Û\8cÙ\84Û\8cبâ\80\8cدÛ\8cر.",
        "wlnote": "آشاغیداکی {{PLURAL:$1|بیر ديَیشیک‌لیک|<strong>$1</strong> ديَیشیک‌لیک}}  سون {{PLURAL:$2|ساعتدا|<strong>$2</strong> ساعتدا}} ائدیلمیشدیر. $3، $4",
        "wlshowlast": "سون $1 ساعات $2 گون گؤستر",
        "watchlist-options": "ایزله‌دیکلر سئچمه‌لری",
        "watching": "ایزله‌نیلیر...",
        "unwatching": "ایزله‌مه...",
        "watcherrortext": "ایزلئمئ سیاهی‌سی ترجیحلرینیزی \"$1\" اوچون دییشدیررکن بیر خطا میدانا گلدی.",
-       "enotif_reset": "باخیلمیش بوتون صحیفه‌لری ایشاره‌له.",
+       "enotif_reset": "باخیلمیش بۆتون صفحه‌لری علامت‌له.",
        "enotif_impersonal_salutation": "{{SITENAME}} ایستیفاده‌چی‌سی",
        "enotif_subject_deleted": "{{SITENAME}} $1 صحیفه‌سی، {{gender:$2|$2}} ایله سیلینیب‌دیر",
        "enotif_subject_created": "{{SITENAME}} $1 صحیفه‌سی، {{gender:$2|$2}} ایله یارانیب‌دیر",
        "invert": "سئچیلنی دؤندر",
        "tooltip-invert": "بو قوتونی علامتله یین تا انتخاب اولان آد فضا سینین ایچری صحیفه لری دییشیک لیک لری(و اوبیری علامتلنمیش فضالار) گیزله نه آدی",
        "tooltip-whatlinkshere-invert": "سئچیلمیش آدفضاسیندان اولان باغلانتیلاری گیزلتمک اوچون بو قوتویا نیشان قویون.",
-       "namespace_association": "اÛ\8cÙ\84Ú¯Û\8cلی آدفضاسی",
+       "namespace_association": "باغلی آدفضاسی",
        "tooltip-namespace_association": "بو قوتونو علامت له ین یالنیز آد بحث فضاسی یا مرتبط اولان آد فضاسی ایله انتخاب اولا",
        "blanknamespace": "(آنا)",
        "contributions": "{{GENDER:$1|ایشلدن}} چالیشمالاری",
        "previousdiff": "اسکی دَییشدیرمه",
        "nextdiff": "یئنی دَییشدیرمه",
        "mediawarning": "'''خبردارلیق: بو ​​فایل نوعو پیس نیت‌لی کودلار اولا بیلر.\nبونو ایشلتمک، سیستئمینیزی تهلوکه‌یه آتا بیلر.",
-       "imagemaxsize": "گؤرونتو ماکسیمال توتومو:<br />(فایلین تصویری صفحه‌لری اۆچون)'",
+       "imagemaxsize": "عکس ماکسیمال توتومو:<br />(فایلین تصویری صفحه‌لری اۆچون)'",
        "thumbsize": "کیچیک اؤلچو:",
        "widthheightpage": "$1 × $2، $3 {{PLURAL:$3|صحیف|صحیفه‌لر}}",
        "file-info": "فایلین اؤلچوسو: $1، MIME تیپی: $2",
        "tags-edit-nooldid-title": "گئچرسیز هدف نوسخه",
        "comparepages": "صحیفه‌لری قارشی‌لاش‌دیر",
        "compare-page1": "صفحه 1",
-       "compare-page2": "صحیفه 2",
+       "compare-page2": "صفحه ۲",
        "compare-rev1": "نوسخه ۱",
        "compare-rev2": "نوسخه ۲",
        "compare-submit": "قارشی‌لاش‌دیر",
index 8d09e41..ef97433 100644 (file)
        "right-bot": "лічыцца аўтаматычным працэсам",
        "right-nominornewtalk": "не паведамляць удзельнікам пра новыя паведамленьні на іх старонках гутарак, калі зробленыя там праўкі былі дробнымі",
        "right-apihighlimits": "менш абмежаваньняў на выкананьне API-запытаў",
-       "right-writeapi": "выкарыстаньне API для запісаў",
+       "right-writeapi": "выкарыстаньне API для запісу",
        "right-delete": "выдаленьне старонак",
        "right-bigdelete": "Выдаленьне старонак зь вялікімі гісторыямі",
        "right-deletelogentry": "выдаленьне і аднаўленьне асобных запісаў журналу",
        "recentchangeslinked-feed": "Зьвязаныя праўкі",
        "recentchangeslinked-toolbox": "Зьвязаныя праўкі",
        "recentchangeslinked-title": "Зьвязаныя праўкі для «$1»",
-       "recentchangeslinked-summary": "Гэта сьпіс апошніх зьменаў старонак, на якія спасылаецца азначаная старонка (ці ўсіх старонак, якія належаць азначанай катэгорыі).\nСтаронкі з [[Special:Watchlist|Вашага сьпісу назіраньня]] пазначаныя '''тлустым шрыфтам'''.",
+       "recentchangeslinked-summary": "Гэта сьпіс апошніх зьменаў старонак, на якія спасылаецца азначаная старонка (ці ўсіх старонак, якія належаць азначанай катэгорыі).\nСтаронкі з [[Special:Watchlist|Вашага сьпісу назіраньня]] пазначаныя <strong>тоўстым шрыфтам</strong>.",
        "recentchangeslinked-page": "Назва старонкі:",
        "recentchangeslinked-to": "Замест гэтага паказваць зьмены на старонках, што спасылаюцца на гэтую старонку",
        "upload": "Загрузіць файл",
        "blankpage": "Пустая старонка",
        "intentionallyblankpage": "Гэтая старонка наўмысна пакінутая пустой",
        "external_image_whitelist": " #Пакіньце гэты радок такім, які ён ёсьць<pre>\n#Зьмясьціце часткі рэгулярных выразаў (толькі частку якая знаходзіцца паміж //) ніжэй\n#Яны будуць суаднесеныя з URL-адрасамі вонкавых выяваў\n#Тыя, якія будуць пасаваць будуць паказвацца як выявы, астатнія толькі як спасылкі\n#Радкі, пазначаныя #, лічыцца камэнтарамі\n#Рэгістар сымбаляў ня ўлічваецца\n\n#Зьмясьціце ўсе часткі рэгулярных выразаў над гэтым радком. Сам радок пакіньце ў такім жа выглядзе</pre>",
-       "tags": "СлÑ\83Ñ\88нÑ\8bÑ\8f Ñ\82Ñ\8dгі зьменаў",
-       "tag-filter": "Фільтар [[Special:Tags|тэгаў]]:",
+       "tags": "Ð\94зейнÑ\8bÑ\8f Ð¼ÐµÑ\82кі зьменаў",
+       "tag-filter": "Фільтар [[Special:Tags|метак]]:",
        "tag-filter-submit": "Фільтар",
-       "tag-list-wrapper": "([[Special:Tags|{{PLURAL:$1|1=ТÑ\8dг|ТÑ\8dгі}}]]: $2)",
+       "tag-list-wrapper": "([[Special:Tags|{{PLURAL:$1|1=Ð\9cеÑ\82ка|Ð\9cеÑ\82кі}}]]: $2)",
        "tags-title": "Меткі",
-       "tags-intro": "На гэтай старонцы знаходзіцца сьпіс тэгаў, якімі праграмнае забесьпячэньне можа пазначыць рэдагаваньне, і іх значэньне.",
-       "tags-tag": "Назва тэга",
+       "tags-intro": "На гэтай старонцы знаходзіцца сьпіс метак, якімі праграмнае забесьпячэньне можа пазначыць рэдагаваньне, і іх значэньне.",
+       "tags-tag": "Назва меткі",
        "tags-display-header": "Новыя запісы ў сьпісе зьменаў",
        "tags-description-header": "Поўнае апісаньне значэньня",
        "tags-source-header": "Крыніца",
        "tags-apply-not-allowed-one": "Метка «$1» ня можа быць прызначаная ўручную.",
        "tags-apply-not-allowed-multi": "{{PLURAL:$2|Наступную метку|Наступныя меткі}} нельга дадаваць уручную: $1",
        "tags-update-no-permission": "Вы ня маеце права на дадаваньне ці выдаленьне метак зьменаў для асобных вэрсіяў ці запісаў журналаў.",
+       "tags-update-add-not-allowed-one": "Метка «$1» ня можа быць дададзеная ўручную.",
+       "tags-update-add-not-allowed-multi": "{{PLURAL:$2|1=Наступную метку|Наступныя меткі}} нельга дадаваць уручную: $1",
+       "tags-update-remove-not-allowed-one": "Метка «$1» ня можа быць выдаленая.",
+       "tags-update-remove-not-allowed-multi": "{{PLURAL:$2|1=Наступная метка на можа быць выдаленая|Наступныя меткі ня могуць быць выдаленыя}} ўручную: $1",
        "tags-edit-title": "Рэдагаваньне метак",
        "tags-edit-manage-link": "Кіраваньне меткамі",
        "tags-edit-revision-selected": "{{PLURAL:$1|1=Абраная вэрсія|Абраныя вэрсіі}} [[:$2]]:",
index b0a7ed1..acfd01c 100644 (file)
@@ -8,48 +8,48 @@
                        "SatyamMishra"
                ]
        },
-       "tog-underline": "लिà¤\82à¤\95 à¤\95à¥\87 à¤¨à¥\80à¤\9aà¥\87 à¤°à¥\87à¤\96ा",
-       "tog-hideminor": "हाल à¤\95à¥\87 à¤ªà¤°à¤¿à¤µà¤°à¥\8dतन à¤®à¥\87à¤\82 à¤®à¤¾à¤®à¥\82लà¥\80 à¤¸à¤\82पादन à¤\9bà¥\81पाईं",
-       "tog-hidepatrolled": "हाल à¤\95à¥\87 à¤ªà¤°à¤¿à¤µà¤°à¥\8dतन à¤®à¥\87à¤\82 à¤®à¤¾à¤®à¥\82लà¥\80 à¤¸à¤\82पादन à¤\9bà¥\81पाईं",
-       "tog-newpageshidepatrolled": "नयà¤\95ा à¤ªà¥\83षà¥\8dठ à¤\95à¥\87 à¤¸à¥\82à¤\9aà¥\80 à¤®à¥\87à¤\82 à¤¸à¥\87 à¤\9cाà¤\81à¤\9aल à¤ªà¥\83षà¥\8dà¤\95 à¤\95à¥\87 à¤\9bà¥\81पाà¤\81à¤\88",
-       "tog-extendwatchlist": "मातà¥\8dर à¤¹à¤¾à¤² à¤\95à¥\87 à¤ªà¤°à¤¿à¤µà¤°à¥\8dतन à¤¹à¥\80 à¤¨à¤¾à¤¹à¥\80,बलà¥\8dà¤\95ि à¤¸à¤¬ à¤ªà¤°à¤¿à¤µà¤°à¥\8dतन à¤\95à¥\87 à¤¦à¥\87à¤\96ावà¥\87 à¤\96ातिर à¤§à¥\8dयान à¤¸à¥\82à¤\9aà¥\80 à¤\95à¥\87 à¤µिस्तारित करीं",
-       "tog-usenewrc": "तà¥\81रà¤\82त à¤­à¤\87ल à¤ªà¤°à¤¿à¤µà¤°à¥\8dतन à¤®à¥\87à¤\82 à¤\86 à¤§à¥\8dयानसà¥\82à¤\9aà¥\80 à¤®à¥\87à¤\82 à¤­à¤\87ल à¤ªà¤°à¤¿à¤µà¤°à¥\8dतनन à¤\95à¥\87 à¤ªà¤¨à¥\8dना à¤\85नà¥\81सार à¤¸à¤®à¥\82ह में बांटी",
-       "tog-numberheadings": "सà¥\8dवयà¤\82-साà¤\82à¤\96à¥\8dयिà¤\95à¥\80 à¤¶à¤¿à¤°à¥\8dषà¤\95",
-       "tog-showtoolbar": "समà¥\8dपादन à¤\94à¤\9cारपà¤\9fà¥\8dà¤\9fà¥\80 à¤\95à¥\87 à¤¦à¤¿खावल जाव",
-       "tog-editondblclick": "दà¥\81à¤\88 à¤\95à¥\8dलिà¤\95 à¤ªà¤° à¤ªà¤¨à¥\8dना संपादन करीं",
-       "tog-editsectiononrightclick": "à¤\85नà¥\81भाà¤\97 à¤¶à¥\80रà¥\8dषà¤\95 à¤ªà¤° à¤¦à¤¾à¤¯à¤¾à¤\81 à¤\95à¥\8dलिà¤\95 à¤\95र à¤\85नà¥\81भाà¤\97 सम्पादित करीं",
-       "tog-watchcreations": "हमरा à¤¦à¥\8dवारा à¤¨à¤¿à¤°à¥\8dमित à¤ªà¥\83षà¥\8dठ à¤\86 à¤¹à¤®à¤°à¤¾ à¤¦à¥\8dवारा à¤²à¤¾à¤¦à¤² à¤«à¤¼à¤¾à¤