Followup r75763, fixup wrong change of deprecated method
authorSam Reed <reedy@users.mediawiki.org>
Sun, 12 Dec 2010 18:35:19 +0000 (18:35 +0000)
committerSam Reed <reedy@users.mediawiki.org>
Sun, 12 Dec 2010 18:35:19 +0000 (18:35 +0000)
No need to do separate htmlspecialchars et al, Xml::expandAttributes

includes/EditPage.php
includes/diff/DifferenceEngine.php

index 6d2b01e..f1b5998 100644 (file)
@@ -1223,7 +1223,7 @@ class EditPage {
                if ( $this->showHeader() === false )
                        return;
 
-               $action = htmlspecialchars($this->getActionURL($wgTitle));
+               $action = htmlspecialchars( $this->getActionURL( $wgTitle ) );
 
                if ( $wgUser->getOption( 'showtoolbar' ) and !$this->isCssJsSubpage ) {
                        # prepare toolbar for edit buttons
@@ -2355,7 +2355,9 @@ HTML
                        );
                        $checkboxes['minor'] =
                                Xml::check( 'wpMinoredit', $checked['minor'], $attribs ) .
-                               "&#160;<label for='wpMinoredit' id='mw-editpage-minoredit'" . $skin->titleAttrib( 'minoredit', 'withaccess' ) . ">{$minorLabel}</label>";
+                               "&#160;<label for='wpMinoredit' id='mw-editpage-minoredit'" .
+                               Xml::expandAttributes( array( 'title' => $skin->titleAttrib( 'minoredit', 'withaccess' ) ) ) .
+                               ">{$minorLabel}</label>";
                }
 
                $watchLabel = wfMsgExt( 'watchthis', array( 'parseinline' ) );
@@ -2368,7 +2370,9 @@ HTML
                        );
                        $checkboxes['watch'] =
                                Xml::check( 'wpWatchthis', $checked['watch'], $attribs ) .
-                               "&#160;<label for='wpWatchthis' id='mw-editpage-watch'" . $skin->titleAttrib( 'watch', 'withaccess' ) . ">{$watchLabel}</label>";
+                               "&#160;<label for='wpWatchthis' id='mw-editpage-watch'" .
+                               Xml::expandAttributes( array( 'title' => $skin->titleAttrib( 'watch', 'withaccess' ) ) ) .
+                               ">{$watchLabel}</label>";
                }
                wfRunHooks( 'EditPageBeforeEditChecks', array( &$this, &$checkboxes, &$tabindex ) );
                return $checkboxes;
index b295c57..ff2d247 100644 (file)
@@ -1006,7 +1006,7 @@ CONTROL;
                                'undo' => $this->mNewid
                        ) );
                        $htmlLink = htmlspecialchars( wfMsg( 'editundo' ) );
-                       $htmlTitle = $wgUser->getSkin()->titleAttrib( 'undo' );
+                       $htmlTitle = Xml::expandAttributes( array( 'title' => $skin->titleAttrib( 'undo' ) ) );
                        if ( $editable && !$this->mOldRev->isDeleted( Revision::DELETED_TEXT ) && !$this->mNewRev->isDeleted( Revision::DELETED_TEXT ) ) {
                                $this->mNewtitle .= " (<a href='$newUndo' $htmlTitle>" . $htmlLink . "</a>)";
                        }