allow to enable full tidy
authorDomas Mituzas <midom@users.mediawiki.org>
Mon, 23 Jan 2006 20:57:57 +0000 (20:57 +0000)
committerDomas Mituzas <midom@users.mediawiki.org>
Mon, 23 Jan 2006 20:57:57 +0000 (20:57 +0000)
includes/DefaultSettings.php
includes/Parser.php

index 1de1d1c..b971c6b 100644 (file)
@@ -1400,6 +1400,7 @@ $wgRawHtml = false;
  *   'extension=tidy.so' to php.ini.
  */
 $wgUseTidy = false;
+$wgAlwaysUseTidy = false;
 $wgTidyBin = 'tidy';
 $wgTidyConf = $IP.'/extensions/tidy/tidy.conf';
 $wgTidyOpts = '';
index 8a75a24..97b18c6 100644 (file)
@@ -176,7 +176,7 @@ class Parser
                 * to internalParse() which does all the real work.
                 */
 
-               global $wgUseTidy, $wgContLang;
+               global $wgUseTidy, $wgAlwaysUseTidy, $wgContLang;
                $fname = 'Parser::parse';
                wfProfileIn( $fname );
 
@@ -237,7 +237,7 @@ class Parser
 
                $text = Sanitizer::normalizeCharReferences( $text );
 
-               if ($wgUseTidy and $this->mOptions->mTidy) {
+               if (($wgUseTidy and $this->mOptions->mTidy) or $wgAlwaysUseTidy) {
                        $text = Parser::tidy($text);
                }