From: Raimond Spekking Date: Tue, 15 Apr 2008 12:54:07 +0000 (+0000) Subject: Localize the group names X-Git-Tag: 1.31.0-rc.0~48314 X-Git-Url: http://git.cyclocoop.org/%22.%24image2.%22?a=commitdiff_plain;h=dc39182d7ac2f01cf79115bc8b2b4ca0e086be9e;p=lhc%2Fweb%2Fwiklou.git Localize the group names --- diff --git a/includes/SpecialListgrouprights.php b/includes/SpecialListgrouprights.php index 842b6a54cb..b3a4a050ab 100644 --- a/includes/SpecialListgrouprights.php +++ b/includes/SpecialListgrouprights.php @@ -38,11 +38,19 @@ class SpecialListGroupRights extends SpecialPage { ); foreach( $wgGroupPermissions as $group => $permissions ) { - $groupname = htmlspecialchars( $group ); + $groupname = ( $group == '*' ) ? 'all' : htmlspecialchars( $group ); // Replace * with a more descriptive groupname + + $msg = wfMsg( 'group-' . $groupname ); + if ( wfEmptyMsg( 'group-' . $groupname, $msg ) || $msg == '' ) { + $groupnameLocalized = $groupname; + } else { + $groupnameLocalized = $msg; + } + if ( in_array( $group, $wgImplicitGroups ) ) - $grouplink = $groupname; + $grouplink = $groupnameLocalized; else - $grouplink = $this->skin->makeKnownLinkObj( SpecialPage::getTitleFor( 'Listusers' ), $groupname, 'group=' . $group ); + $grouplink = $this->skin->makeKnownLinkObj( SpecialPage::getTitleFor( 'Listusers' ), $groupnameLocalized, 'group=' . $group ); $wgOut->addHTML( '