$dbr->addQuotes( '/' ),
'img_minor_mime',
$dbr->addQuotes( ';' ),
- 'COUNT(*)',
+ $dbr->buildStringCast( 'COUNT(*)' ),
$dbr->addQuotes( ';' ),
- 'SUM( img_size )'
+ $dbr->buildStringCast( 'SUM( img_size )' )
] );
return [
'tables' => [ 'image' ],
* Output closing </table>
*/
protected function outputTableEnd() {
- $this->getOutput()->addHTML( Html::closeElement( 'table' ) );
+ $this->getOutput()->addHTML(
+ Html::closeElement( 'tbody' ) .
+ Html::closeElement( 'table' )
+ );
$this->getOutput()->addWikiTextAsInterface(
$this->msg( 'mediastatistics-bytespertype' )
->numParams( $this->totalPerType )
* @param string $mediaType
*/
protected function outputTableStart( $mediaType ) {
- $this->getOutput()->addHTML(
+ $out = $this->getOutput();
+ $out->addModuleStyles( 'jquery.tablesorter.styles' );
+ $out->addModules( 'jquery.tablesorter' );
+ $out->addHTML(
Html::openElement(
'table',
[ 'class' => [
'sortable',
'wikitable'
] ]
- )
+ ) .
+ Html::rawElement( 'thead', [], $this->getTableHeaderRow() ) .
+ Html::openElement( 'tbody' )
);
- $this->getOutput()->addHTML( $this->getTableHeaderRow() );
}
/**