Revision: 46151
Author: ialex
Date: 2009-01-24 17:42:12 +0000 (Sat, 24 Jan 2009)
Log Message:
-----------
* Removed false comment, we are in a Category page, not an Image page
* Use wfMsgExt( 'msg', array( 'escape' ), ... ) rather than htmlspecialchars(
wfMsg( ... ) )
* Whitespaces tweaks
Modified Paths:
--------------
trunk/phase3/includes/CategoryPage.php
Modified: trunk/phase3/includes/CategoryPage.php
===================================================================
--- trunk/phase3/includes/CategoryPage.php 2009-01-24 17:26:54 UTC (rev
46150)
+++ trunk/phase3/includes/CategoryPage.php 2009-01-24 17:42:12 UTC (rev
46151)
@@ -20,7 +20,8 @@
if ( isset( $diff ) && $diffOnly )
return Article::view();
- if(!wfRunHooks('CategoryPageView', array(&$this))) return;
+ if( !wfRunHooks( 'CategoryPageView', array( &$this ) ) )
+ return;
if ( NS_CATEGORY == $this->mTitle->getNamespace() ) {
$this->openShowCategory();
@@ -28,10 +29,6 @@
Article::view();
- # If the article we've just shown is in the "Image" namespace,
- # follow it with the history list and link list for the image
- # it describes.
-
if ( NS_CATEGORY == $this->mTitle->getNamespace() ) {
$this->closeShowCategory();
}
@@ -79,7 +76,7 @@
$this->from = $from;
$this->until = $until;
$this->limit = $wgCategoryPagingLimit;
- $this->cat = Category::newFromName( $title->getDBKey() );
+ $this->cat = Category::newFromTitle( $title );
}
/**
@@ -317,7 +314,7 @@
$countmsg = $this->getCountMessage( $rescnt, $dbcnt,
'file' );
return "<div id=\"mw-category-media\">\n" .
- '<h2>' . wfMsg( 'category-media-header',
htmlspecialchars($this->title->getText()) ) . "</h2>\n" .
+ '<h2>' . wfMsg( 'category-media-header',
htmlspecialchars( $this->title->getText() ) ) . "</h2>\n" .
$countmsg . $this->gallery->toHTML() . "\n</div>";
} else {
return '';
@@ -452,12 +449,12 @@
$sk = $this->getSkin();
$limitText = $wgLang->formatNum( $limit );
- $prevLink = htmlspecialchars( wfMsg( 'prevn', $limitText ) );
+ $prevLink = wfMsgExt( 'prevn', array( 'escape' ), $limitText );
if( $first != '' ) {
$prevLink = $sk->makeLinkObj( $title, $prevLink,
wfArrayToCGI( $query + array( 'until' => $first
) ) );
}
- $nextLink = htmlspecialchars( wfMsg( 'nextn', $limitText ) );
+ $nextLink = wfMsgExt( 'nextn', array( 'escape' ), $limitText );
if( $last != '' ) {
$nextLink = $sk->makeLinkObj( $title, $nextLink,
wfArrayToCGI( $query + array( 'from' => $last )
) );
_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs