mediawiki-extensions-AbuseF.../Views/AbuseFilterViewImport.php

25 lines
660 B
PHP
Raw Normal View History

<?php
class AbuseFilterViewImport extends AbuseFilterView {
function show() {
$out = $this->getOutput();
if ( !$this->getUser()->isAllowed( 'abusefilter-modify' ) ) {
$out->addWikiMsg( 'abusefilter-edit-notallowed' );
return;
}
$out->addWikiMsg( 'abusefilter-import-intro' );
$html = Xml::textarea( 'wpImportText', '', 40, 20 );
2010-03-13 17:35:12 +00:00
$html .= Xml::submitButton(
$this->msg( 'abusefilter-import-submit' )->text(),
2010-03-13 17:35:12 +00:00
array( 'accesskey' => 's' )
);
$url = SpecialPage::getTitleFor( 'AbuseFilter', 'new' )->getFullURL();
$html = Xml::tags( 'form', array( 'method' => 'post', 'action' => $url ), $html );
$out->addHTML( $html );
}
}