r48720 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r48719‎ | r48720 | r48721 >
Date:21:20, 23 March 2009
Author:raymond
Status:ok (Comments)
Tags:todo 
Comment:
Add a class to the table and use a nice Xml::function
Wrap text of intro in a div with own class
Modified paths:
  • /trunk/phase3/includes/specials/SpecialTags.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/specials/SpecialTags.php
@@ -13,10 +13,10 @@
1414 global $wgOut, $wgUser, $wgMessageCache;
1515
1616 $wgMessageCache->loadAllMessages();
17 -
 17+
1818 $sk = $wgUser->getSkin();
1919 $wgOut->setPageTitle( wfMsg( 'tags-title' ) );
20 - $wgOut->addWikiMsg( 'tags-intro' );
 20+ $wgOut->wrapWikiMsg( "<div class='mw-tags-intro'>\n$1</div>", 'tags-intro' );
2121
2222 // Write the headers
2323 $html = '';
@@ -36,9 +36,7 @@
3737 $html .= $this->doTagRow( $tag, 0 );
3838 }
3939
40 - $html = "<table style='width: 80%'><tbody>$html</tbody></table>";
41 -
42 - $wgOut->addHTML( $html );
 40+ $wgOut->addHTML( Xml::tags( 'table', array( 'style' => 'width: 80%', 'class' => 'mw-tags-table' ), $html ) );
4341 }
4442
4543 function doTagRow( $tag, $hitcount ) {

Follow-up revisions

RevisionCommit summaryAuthorDate
r48792Fix per comment in r48720: Remove style from code and use same table stylings...raymond08:09, 25 March 2009

Comments

#Comment by Brion VIBBER (talk | contribs)   20:01, 24 March 2009

The style should get moved out to CSS prolly.

#Comment by Raymond (talk | contribs)   08:11, 25 March 2009

Fixed in r48792: Now using the same stylings as other tables.

Status & tagging log