summaryrefslogtreecommitdiff
path: root/includes/SpecialImagelist.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/SpecialImagelist.php')
-rw-r--r--includes/SpecialImagelist.php22
1 files changed, 11 insertions, 11 deletions
diff --git a/includes/SpecialImagelist.php b/includes/SpecialImagelist.php
index 5ecbe8a6..92b9ae11 100644
--- a/includes/SpecialImagelist.php
+++ b/includes/SpecialImagelist.php
@@ -1,8 +1,7 @@
<?php
/**
*
- * @package MediaWiki
- * @subpackage SpecialPage
+ * @addtogroup SpecialPage
*/
/**
@@ -24,6 +23,10 @@ function wfSpecialImagelist() {
. $nav );
}
+/**
+ * @addtogroup SpecialPage
+ * @addtogroup Pager
+ */
class ImageListPager extends TablePager {
var $mFieldNames = null;
var $mMessages = array();
@@ -40,11 +43,11 @@ class ImageListPager extends TablePager {
if ( $search != '' && !$wgMiserMode ) {
$nt = Title::newFromUrl( $search );
if( $nt ) {
- $dbr =& wfGetDB( DB_SLAVE );
+ $dbr = wfGetDB( DB_SLAVE );
$m = $dbr->strencode( strtolower( $nt->getDBkey() ) );
$m = str_replace( "%", "\\%", $m );
$m = str_replace( "_", "\\_", $m );
- $this->mQueryConds = array( "LCASE(img_name) LIKE '%{$m}%'" );
+ $this->mQueryConds = array( "LOWER(img_name) LIKE '%{$m}%'" );
}
}
@@ -138,17 +141,14 @@ class ImageListPager extends TablePager {
function getForm() {
global $wgRequest, $wgMiserMode;
$url = $this->getTitle()->escapeLocalURL();
- $msgSubmit = wfMsgHtml( 'table_pager_limit_submit' );
- $msgSearch = wfMsgHtml( 'imagelist_search_for' );
$search = $wgRequest->getText( 'ilsearch' );
- $encSearch = htmlspecialchars( $search );
- $s = "<form method=\"get\" action=\"$url\">\n" .
+ $s = "<form method=\"get\" action=\"$url\">\n" .
wfMsgHtml( 'table_pager_limit', $this->getLimitSelect() );
if ( !$wgMiserMode ) {
- $s .= "<br/>\n" . $msgSearch .
- " <input type=\"text\" size=\"20\" name=\"ilsearch\" value=\"$encSearch\"/><br/>\n";
+ $s .= "<br/>\n" .
+ Xml::inputLabel( wfMsg( 'imagelist_search_for' ), 'ilsearch', 'mw-ilsearch', 20, $search );
}
- $s .= " <input type=\"submit\" value=\"$msgSubmit\"/>\n" .
+ $s .= " " . Xml::submitButton( wfMsg( 'table_pager_limit_submit' ) ) ." \n" .
$this->getHiddenFields( array( 'limit', 'ilsearch' ) ) .
"</form>\n";
return $s;