* Updated to use the new revid system in the parser

This commit is contained in:
Ævar Arnfjörð Bjarmason 2005-11-27 08:16:59 +00:00
parent 2e67b02cc7
commit 31b0865dd5

View file

@ -132,7 +132,6 @@ function wfSpecialCite() {
$this->mTitle =& $title;
$this->mArticle =& $article;
$wgHooks['ParserGetVariableValueRevid'][] = array( $this, 'revid' );
$wgHooks['ParserGetVariableValueVarCache'][] = array( $this, 'varCache' );
$this->genParserOptions();
@ -147,7 +146,8 @@ function wfSpecialCite() {
$wgHooks['ParserGetVariableValueTs'][] = array( $this, 'timestamp' );
$msg = wfMsgForContentNoTrans( 'cite_text' );
$ret = $wgParser->parse( $msg, &$this->mTitle, $this->mParserOptions );
$this->mArticle->fetchContent();
$ret = $wgParser->parse( $msg, &$this->mTitle, $this->mParserOptions, false, true, $this->mArticle->getRevIdFetched() );
$wgOut->addHtml( $ret->getText() );
}
@ -177,13 +177,6 @@ function wfSpecialCite() {
return true;
}
function revid( &$parser, &$revid ) {
$this->mArticle->fetchContent();
$revid = $this->mArticle->getRevIdFetched();
return false;
}
}
SpecialPage::addPage( new Cite );