* doExponant() function. Convert ^^th^^ in <small><sup>th</sup></small>.
authorAntoine Musso <hashar@users.mediawiki.org>
Thu, 17 Jun 2004 17:29:54 +0000 (17:29 +0000)
committerAntoine Musso <hashar@users.mediawiki.org>
Thu, 17 Jun 2004 17:29:54 +0000 (17:29 +0000)
The function call is commented

includes/Parser.php

index 5d6a7c7..ff8a94f 100644 (file)
@@ -786,6 +786,7 @@ cl_sortkey" ;
                        $text = $wgDateFormatter->reformat( $this->mOptions->getDateFormat(), $text );
                }
                $text = $this->doAllQuotes( $text );
+               // $text = $this->doExponant( $text );
                $text = $this->replaceExternalLinks( $text );
                $text = $this->replaceInternalLinks ( $text );
                $text = $this->replaceInternalLinks ( $text );
@@ -805,6 +806,16 @@ cl_sortkey" ;
                wfProfileOut( $fname );
                return $text;
        }
+       
+       # Parse ^^ tokens and return html
+       /* private */ function doExponant ( $text )
+       {
+               $fname = 'Parser::doExponant';
+               wfProfileIn( $fname);
+               $text = preg_replace('/\^\^(.*)\^\^/','<small><sup>\\1</sup></small>', $text);
+               wfProfileOut( $fname);
+               return $text;
+       }
 
     # Parse headers and return html
        /* private */ function doHeadings( $text ) {