* Added md5 parameter to action=edit
* (bug 14335) Logging in to unified account using API not possible
* Added action=emailuser to send an email to a user
+* (bug 14471) Use HTMLTidy and generate limit report in action=parse
=== Languages updated in 1.13 ===
$revid = false;
global $wgParser, $wgUser;
+ $popts = new ParserOptions();
+ $popts->setTidy(true);
+ $popts->enableLimitReport();
if(!is_null($oldid) || !is_null($page))
{
if(!is_null($oldid))
$this->dieUsage("You don't have permission to view deleted revisions", 'permissiondenied');
$text = $rev->getRawText();
$titleObj = $rev->getTitle();
- $p_result = $wgParser->parse($text, $titleObj, new ParserOptions());
+ $p_result = $wgParser->parse($text, $titleObj, $popts);
}
else
{
$pcache = ParserCache::singleton();
$p_result = $pcache->get($articleObj, $wgUser);
if(!$p_result) {
- $p_result = $wgParser->parse($articleObj->getContent(), $titleObj, new ParserOptions());
+ $p_result = $wgParser->parse($articleObj->getContent(), $titleObj, $popts);
global $wgUseParserCache;
if($wgUseParserCache)
$pcache->save($p_result, $articleObj, $wgUser);
$titleObj = Title::newFromText($title);
if(!$titleObj)
$titleObj = Title::newFromText("API");
- $p_result = $wgParser->parse($text, $titleObj, new ParserOptions());
+ $p_result = $wgParser->parse($text, $titleObj, $popts);
}
// Return result