Last modified: 2010-05-15 15:37:19 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 3339 - Redirected from (using ?rdfrom=...) is not shown when page is cached
Redirected from (using ?rdfrom=...) is not shown when page is cached
Product: MediaWiki
Classification: Unclassified
Parser (Other open bugs)
All All
: Low normal (vote)
: ---
Assigned To: Nobody - You can work on this!
: patch, patch-need-review
Depends on:
  Show dependency treegraph
Reported: 2005-09-02 21:47 UTC by Dave Miller (ProgMania)
Modified: 2010-05-15 15:37 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Description Dave Miller (ProgMania) 2005-09-02 21:47:50 UTC
When $wgRedirectSources is enabled, the 'Redirected from ...' line is not shown if the page is 

Reason (as far as I can tell):
In includes/Article.php, the part about redirects (starting '} elseif ( !empty( $rdfrom ) ) {') is 
inside the 'if ( !$outputDone ) {' (if not cached) section but the redirected from line is not 
cached (because it changes).

Quick Fix:

if ( $wgOut->tryParserCache( $this, $wgUser ) ) {
	$outputDone = true;

if ( $wgOut->tryParserCache( $this, $wgUser ) ) {
	if ($rdfrom) {
		$sk = $wgUser->getSkin();
		$redir = $sk->makeExternalLink( $rdfrom, $rdfrom );
		$s = wfMsg( 'redirectedfrom', $redir );
		$wgOut->setSubtitle( $s );
	$outputDone = true;
Comment 1 Aaron Schulz 2008-09-27 23:56:11 UTC
No longer the case it seems

Note You need to log in before you can comment on or make changes to this bug.