$out = $this->getOutput();
$lang = $this->getLanguage();
$out->setPageTitle( $this->msg( 'ipblocklist' ) );
$out = $this->getOutput();
$lang = $this->getLanguage();
$out->setPageTitle( $this->msg( 'ipblocklist' ) );
$request = $this->getRequest();
$par = $request->getVal( 'ip', $par );
$this->target = trim( $request->getVal( 'wpTarget', $par ) );
$request = $this->getRequest();
$par = $request->getVal( 'ip', $par );
$this->target = trim( $request->getVal( 'wpTarget', $par ) );
'label-message' => 'ipaddressorusername',
'tabindex' => '1',
'size' => '45',
'default' => $this->target,
'label-message' => 'ipaddressorusername',
'tabindex' => '1',
'size' => '45',
'default' => $this->target,
'blocklist-userblocks' => 'userblocks',
'blocklist-tempblocks' => 'tempblocks',
'blocklist-addressblocks' => 'addressblocks',
'blocklist-rangeblocks' => 'rangeblocks',
'blocklist-userblocks' => 'userblocks',
'blocklist-tempblocks' => 'tempblocks',
'blocklist-addressblocks' => 'addressblocks',
'blocklist-rangeblocks' => 'rangeblocks',
$lang->formatNum( 20 ) => 20,
$lang->formatNum( 50 ) => 50,
$lang->formatNum( 100 ) => 100,
$lang->formatNum( 250 ) => 250,
$lang->formatNum( 500 ) => 500,
$lang->formatNum( 20 ) => 20,
$lang->formatNum( 50 ) => 50,
$lang->formatNum( 100 ) => 100,
$lang->formatNum( 250 ) => 250,
$lang->formatNum( 500 ) => 500,
$context = new DerivativeContext( $this->getContext() );
$context->setTitle( $this->getPageTitle() ); // Remove subpage
$context = new DerivativeContext( $this->getContext() );
$context->setTitle( $this->getPageTitle() ); // Remove subpage
$form->setMethod( 'get' );
$form->setWrapperLegendMsg( 'ipblocklist-legend' );
$form->setSubmitTextMsg( 'ipblocklist-submit' );
$form->setMethod( 'get' );
$form->setWrapperLegendMsg( 'ipblocklist-legend' );
$form->setSubmitTextMsg( 'ipblocklist-submit' );
# Is the user allowed to see hidden blocks?
if ( !$this->getUser()->isAllowed( 'hideuser' ) ) {
$conds['ipb_deleted'] = 0;
# Is the user allowed to see hidden blocks?
if ( !$this->getUser()->isAllowed( 'hideuser' ) ) {
$conds['ipb_deleted'] = 0;
list( $start, $end ) = IP::parseRange( $target );
$dbr = wfGetDB( DB_SLAVE );
$conds[] = $dbr->makeList(
list( $start, $end ) = IP::parseRange( $target );
$dbr = wfGetDB( DB_SLAVE );
$conds[] = $dbr->makeList(
'ipb_address' => $target,
Block::getRangeCond( $start, $end )
'ipb_address' => $target,
Block::getRangeCond( $start, $end )
$out = $this->getOutput();
# Check for other blocks, i.e. global/tor blocks
$out = $this->getOutput();
# Check for other blocks, i.e. global/tor blocks
- $otherBlockLink = array();
- Hooks::run( 'OtherBlockLogLink', array( &$otherBlockLink, $this->target ) );
+ $otherBlockLink = [];
+ Hooks::run( 'OtherBlockLogLink', [ &$otherBlockLink, $this->target ] );
# Show additional header for the local block only when other blocks exists.
# Not necessary in a standard installation without such extensions enabled
if ( count( $otherBlockLink ) ) {
$out->addHTML(
# Show additional header for the local block only when other blocks exists.
# Not necessary in a standard installation without such extensions enabled
if ( count( $otherBlockLink ) ) {
$out->addHTML(
$this->msg( 'ipblocklist-otherblocks', count( $otherBlockLink ) )->parse()
) . "\n"
);
$list = '';
foreach ( $otherBlockLink as $link ) {
$this->msg( 'ipblocklist-otherblocks', count( $otherBlockLink ) )->parse()
) . "\n"
);
$list = '';
foreach ( $otherBlockLink as $link ) {
'ipb_timestamp' => 'blocklist-timestamp',
'ipb_target' => 'blocklist-target',
'ipb_expiry' => 'blocklist-expiry',
'ipb_by' => 'blocklist-by',
'ipb_params' => 'blocklist-params',
'ipb_reason' => 'blocklist-reason',
'ipb_timestamp' => 'blocklist-timestamp',
'ipb_target' => 'blocklist-target',
'ipb_expiry' => 'blocklist-expiry',
'ipb_by' => 'blocklist-by',
'ipb_params' => 'blocklist-params',
'ipb_reason' => 'blocklist-reason',
$links[] = Linker::linkKnown(
SpecialPage::getTitleFor( 'Unblock' ),
$msg['unblocklink'],
$links[] = Linker::linkKnown(
SpecialPage::getTitleFor( 'Unblock' ),
$msg['unblocklink'],