Last modified: 2009-09-29 17:22:14 UTC
When viewing a diff via a URL which only contain the diff number, the resulting page link to the main page rather than the page for which the diff occurred in.
This doesn't happen if both "diff" and "oldid" are present in the URL; this only happens when only "diff" is given and "diffonly" is set to "yes".
It looks like when the "oldid" value is not present, the default value of 0 is used, which falls back to Main Page. The diff itself works correctly because in DifferenceEngine.php we have: elseif ( $this->mOldid === 0 ) { $rev = $this->mNewRev->getPrevious(); if( $rev ) { $this->mOldid = $rev->getId(); So the oldid used for the diff is corrected, but that being used to create the content_actions is equal to zero. I couldn't find where exactly this oldid is being used to create the content_actions link relating to the page itself; once it is located, using an approach similar to what I posted above can solve the bug.
*** Bug 14297 has been marked as a duplicate of this bug. ***
> This doesn't happen if both "diff" and "oldid" are present in the URL; this > only happens when only "diff" is given and "diffonly" is set to "yes". > Maybe this is why I thought the bug had been fixed and un-fixed. I recently changed my prefs to diffonly by default. Sorry for duplicate 14297.
(In reply to comment #1) > This doesn't happen if both "diff" and "oldid" are present in the URL; this > only happens when only "diff" is given and "diffonly" is set to "yes". > The above first sentence is correct, but not the second. This does happen even when diffonly is not set. The casuse is when oldid is not set.
*** Bug 14437 has been marked as a duplicate of this bug. ***
Examples from bug 14437: * http://de.wikipedia.org/w/index.php?diff=46942167 (navigation/tabs) * http://de.wikipedia.org/w/index.php?diff=46899942 (pagename) * http://de.wikipedia.org/w/index.php?diff=46992816 (categories)
*** This bug has been marked as a duplicate of bug 15233 ***