(bug 14685) Double underscore magic word usage is now tracked in the page_props table...
authorBryan Tong Minh <btongminh@users.mediawiki.org>
Sat, 10 Jul 2010 11:30:11 +0000 (11:30 +0000)
committerBryan Tong Minh <btongminh@users.mediawiki.org>
Sat, 10 Jul 2010 11:30:11 +0000 (11:30 +0000)
RELEASE-NOTES
includes/parser/Parser.php
includes/parser/ParserOutput.php

index d0d734e..951f718 100644 (file)
@@ -106,6 +106,9 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
 * ForeignApiRepo uses scriptDirUrl if apiBase not set
 * (bug 24212) Added MediaWiki:Filepage.css which is also included on foreign
   client wikis.
+* (bug 14685) Double underscore magic word usage is now tracked in the 
+  page_props table, as well as the behavioral magic words {{DEFAULTSORT}} and 
+  {{DISPLAYTITLE}}
 
 === Bug fixes in 1.17 ===
 * (bug 17560) Half-broken deletion moved image files to deletion archive
index 9ee2499..400029f 100644 (file)
@@ -3634,7 +3634,6 @@ class Parser {
                        $this->mShowToc = false;
                }
                if ( isset( $this->mDoubleUnderscores['hiddencat'] ) && $this->mTitle->getNamespace() == NS_CATEGORY ) {
-                       $this->mOutput->setProperty( 'hiddencat', 'y' );
                        $this->addTrackingCategory( 'hidden-category-category' );
                }
                # (bug 8068) Allow control over whether robots index a page.
@@ -3649,6 +3648,11 @@ class Parser {
                        $this->mOutput->setIndexPolicy( 'index' );
                        $this->addTrackingCategory( 'index-category' );
                }
+               
+               # Cache all double underscores in the database
+               foreach ( $this->mDoubleUnderscores as $key => $val ) {
+                       $this->mOutput->setProperty( $key, '' );
+               }
 
                wfProfileOut( __METHOD__ );
                return $text;
@@ -5137,6 +5141,7 @@ class Parser {
         */
        public function setDefaultSort( $sort ) {
                $this->mDefaultSort = $sort;
+               $this->mOutput->setPropert( 'defaultsort', $sort );
        }
 
        /**
index 1f390a2..cc11049 100644 (file)
@@ -259,6 +259,7 @@ class ParserOutput
         */
        public function setDisplayTitle( $text ) {
                $this->setTitleText( $text );
+               $this->setProperty( 'displaytitle', $text );
        }
 
        /**