Last modified: 2013-03-29 10:45:02 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T18707, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 16707 - Add "rel='next'" link to login page to return to last page.
Add "rel='next'" link to login page to return to last page.
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
User login and signup (Other open bugs)
unspecified
All All
: Normal enhancement (vote)
: ---
Assigned To: Aaron Schulz
: easy, patch, patch-need-review
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2008-12-19 08:47 UTC by Jalsti
Modified: 2013-03-29 10:45 UTC (History)
2 users (show)

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


Attachments

Description Jalsti 2008-12-19 08:47:38 UTC
To enhance the login page I have following proposal which modifies the 'addReturnTo' function, so that modern browsers (like e.g. Opera) hold a 'next' link ready to make it easier for the user to go back to the page where they were before login.

The file is '/var/lib/mediawiki/includes/OutputPage.php' the line numbers were taken from Debian's actual mediawiki version (1.12.0-2lenny1), the modifications are lines 1171-1180 which replace the now commented out line number 1181.

--

1169         public function addReturnTo( $title ) {
1170                 global $wgUser;
1171                 $link= $wgUser->getSkin()->makeLinkObj( $title );
1172
1173                 // create a 'next' link for modern browsers
1174                 $link_next = ereg_replace( '<a href="(.*)" .*', '\\1', $link );
1175                 $this->addLink(
1176                                 array(
1177                                         'rel'   => 'next',
1178                                         'href'  => $link_next ) );
1179
1180                 $link = wfMsg( 'returnto', $link );
1181                 # $link = wfMsg( 'returnto', $wgUser->getSkin()->makeLinkObj( $title ) );
1182                 $this->addHtml( "<p>{$link}</p>\n" );
1183         }

--

Regards, Jalsti

(As this is my first post here, I just can hope everything is placed correctly and completely.)
Comment 1 Aaron Schulz 2008-12-23 21:30:56 UTC
Done in r44977

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


Navigation
Links