From: Alexandre Emsenhuber Date: Thu, 14 Feb 2013 10:29:29 +0000 (+0100) Subject: Add line breaks to the output of action=info X-Git-Tag: 1.31.0-rc.0~20634^2 X-Git-Url: http://git.cyclocoop.org/%24image?a=commitdiff_plain;h=563a5226fe63b1cb8dcab26275bfa07eb9ddf65a;p=lhc%2Fweb%2Fwiklou.git Add line breaks to the output of action=info This makes the source code of the page much more readable. Change-Id: Icf3edc4a108bd4c0821f301986bb3d612071086c --- diff --git a/includes/actions/InfoAction.php b/includes/actions/InfoAction.php index ebedde3003..b61978c10a 100644 --- a/includes/actions/InfoAction.php +++ b/includes/actions/InfoAction.php @@ -81,11 +81,11 @@ class InfoAction extends FormlessAction { // Hide "This page is a member of # hidden categories" explanation $content .= Html::element( 'style', array(), - '.mw-hiddenCategoriesExplanation { display: none; }' ); + '.mw-hiddenCategoriesExplanation { display: none; }' ) . "\n"; // Hide "Templates used on this page" explanation $content .= Html::element( 'style', array(), - '.mw-templatesUsedExplanation { display: none; }' ); + '.mw-templatesUsedExplanation { display: none; }' ) . "\n"; // Get page information $pageInfo = $this->pageInfo(); @@ -95,14 +95,14 @@ class InfoAction extends FormlessAction { // Render page information foreach ( $pageInfo as $header => $infoTable ) { - $content .= $this->makeHeader( $this->msg( "pageinfo-${header}" )->escaped() ); - $table = ''; + $content .= $this->makeHeader( $this->msg( "pageinfo-${header}" )->escaped() ) . "\n"; + $table = "\n"; foreach ( $infoTable as $infoRow ) { $name = ( $infoRow[0] instanceof Message ) ? $infoRow[0]->escaped() : $infoRow[0]; $value = ( $infoRow[1] instanceof Message ) ? $infoRow[1]->escaped() : $infoRow[1]; - $table = $this->addRow( $table, $name, $value ); + $table = $this->addRow( $table, $name, $value ) . "\n"; } - $content = $this->addTable( $content, $table ); + $content = $this->addTable( $content, $table ) . "\n"; } // Page footer