3 * Implements Special:Newimages
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License along
16 * with this program; if not, write to the Free Software Foundation, Inc.,
17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18 * http://www.gnu.org/copyleft/gpl.html
21 * @ingroup SpecialPage
24 class SpecialNewFiles
extends IncludableSpecialPage
{
25 public function __construct() {
26 parent
::__construct( 'Newimages' );
29 public function execute( $par ) {
31 $this->outputHeader();
33 $out = $this->getOutput();
34 $this->addHelpLink( 'Help:New images' );
36 $pager = new NewFilesPager( $this->getContext(), $par );
38 if ( !$this->including() ) {
40 $form = $pager->getForm();
42 $form->displayForm( '' );
45 $out->addHTML( $pager->getBody() );
46 if ( !$this->including() ) {
47 $out->addHTML( $pager->getNavigationBar() );
51 protected function getGroupName() {
56 * Send the text to be displayed above the options
58 function setTopText() {
61 $message = $this->msg( 'newimagestext' )->inContentLanguage();
62 if ( !$message->isDisabled() ) {
63 $this->getOutput()->addWikiText(
64 Html
::rawElement( 'p',
65 [ 'lang' => $wgContLang->getHtmlCode(), 'dir' => $wgContLang->getDir() ],
66 "\n" . $message->plain() . "\n"
68 /* $lineStart */ false,
69 /* $interface */ false