Allow OutputPage::addReturnTo() to set the text of the link.
authorHappy-melon <happy-melon@users.mediawiki.org>
Sat, 13 Mar 2010 16:07:38 +0000 (16:07 +0000)
committerHappy-melon <happy-melon@users.mediawiki.org>
Sat, 13 Mar 2010 16:07:38 +0000 (16:07 +0000)
includes/OutputPage.php

index 24e5c1c..870849d 100644 (file)
@@ -2018,11 +2018,11 @@ class OutputPage {
         * @param $title Title to link
         * @param $query String: query string
         */
-       public function addReturnTo( $title, $query = array() ) {
+       public function addReturnTo( $title, $query = array(), $text=null ) {
                global $wgUser;
                $this->addLink( array( 'rel' => 'next', 'href' => $title->getFullUrl() ) );
                $link = wfMsgHtml( 'returnto', $wgUser->getSkin()->link(
-                       $title, null, array(), $query ) );
+                       $title, $text, array(), $query ) );
                $this->addHTML( "<p id=\"mw-returnto\">{$link}</p>\n" );
        }