r47586 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r47585‎ | r47586 | r47587 >
Date:20:58, 20 February 2009
Author:werdna
Status:ok
Tags:
Comment:
Add right description to GlobalGroupPermission view
Modified paths:
  • /trunk/extensions/CentralAuth/SpecialGlobalGroupPermissions.php (modified) (history)

Diff [purge]

Index: trunk/extensions/CentralAuth/SpecialGlobalGroupPermissions.php
@@ -191,10 +191,14 @@
192192 # Build a checkbox.
193193 $checked = in_array( $right, $assignedRights );
194194
195 - $checkbox = Xml::checkLabel( User::getRightDescription( $right ),
196 - "wpRightAssigned-$right", "wpRightAssigned-$right", $checked, $attribs );
 195+ $desc = htmlspecialchars(User::getRightDescription( $right )) . ' (' .
 196+ Xml::element( 'tt', null, $right ).')';
197197
198 - $checkboxes[] = "<li>$checkbox</li>";
 198+ $checkbox = Xml::check( "wpRightAssigned-$right", $checked, $attribs );
 199+ $label = Xml::tags( 'label', array( 'for' => "wpRightAssigned-$right" ),
 200+ $desc );
 201+
 202+ $checkboxes[] = "<li>$checkbox&nbsp;$label</li>";
199203 }
200204
201205 $count = count($checkboxes);

Status & tagging log