r26059 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r26058‎ | r26059 | r26060 >
Date:04:56, 24 September 2007
Author:simetrical
Status:old
Tags:
Comment:
"' onload='send_me_your_credit_card_info()" would be an interesting page name, don't you think?
Modified paths:
  • /trunk/phase3/includes/OutputPage.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/OutputPage.php
@@ -1282,25 +1282,25 @@
12831283 global $wgSitename;
12841284 $rctitle = SpecialPage::getTitleFor( 'Recentchanges' );
12851285 $link = $rctitle->escapeFullURL( 'feed=rss' );
1286 - $title = wfMsg( 'site-rss-feed', $wgSitename );
 1286+ $title = Sanitizer::encodeAttribute( wfMsg( 'site-rss-feed', $wgSitename ) );
12871287 $ret .= "<link rel='alternate' type='application/rss+xml' title='$title' href='$link' />\n";
12881288 $link = $rctitle->escapeFullURL( 'feed=atom' );
1289 - $title = wfMsg( 'site-atom-feed', $wgSitename );
 1289+ $title = Sanitizer::encodeAttribute( wfMsg( 'site-atom-feed', $wgSitename ) );
12901290 $ret .= "<link rel='alternate' type='application/atom+xml' title='$title' href='$link' />\n";
12911291
12921292 if( $this->isSyndicated() ) {
12931293 # FIXME: centralize the mime-type and name information in Feed.php
1294 - $link = $wgRequest->escapeAppendQuery( 'feed=rss' );
12951294 # Use the page name for the title (accessed through $wgTitle since
12961295 # there's no other way). In principle, this could lead to issues
12971296 # with having the same name for different feeds corresponding to
12981297 # the same page, but we can't avoid that at this low a level.
12991298 global $wgTitle;
13001299 $pagetitle = $wgTitle->getPrefixedText();
1301 - $title = wfMsg( 'page-rss-feed', $pagetitle );
 1300+ $link = $wgRequest->escapeAppendQuery( 'feed=rss' );
 1301+ $title = Sanitizer::encodeAttribute( wfMsg( 'page-rss-feed', $pagetitle ) );
13021302 $ret .= "<link rel='alternate' type='application/rss+xml' title='$title' href='$link' />\n";
13031303 $link = $wgRequest->escapeAppendQuery( 'feed=atom' );
1304 - $title = wfMsg( 'page-atom-feed', $pagetitle );
 1304+ $title = Sanitizer::encodeAttribute( wfMsg( 'page-atom-feed', $pagetitle ) );
13051305 $ret .= "<link rel='alternate' type='application/atom+xml' title='$title' href='$link' />\n";
13061306 }
13071307

Follow-up revisions

RevisionCommit summaryAuthorDate
r26077Clean up r26058, r26059 a bit...brion18:25, 24 September 2007
r26135Merged revisions 26012-26133 via svnmerge from...david21:15, 25 September 2007

Status & tagging log