Open file templates/base/scripts/BxBaseBrowse.php
find this function: function getBlockCode_SearchedMembersBlock
1)
and this code:
// select sorting parameters ;
$sSortParam = '`Profiles`.`DateLastNav` DESC';
if ( isset($this -> aDisplaySettings['sort']) ) {
switch($this -> aDisplaySettings['sort']) {
case 'date_reg' :
$sSortParam = ' `Profiles`.`DateReg` DESC';
break;
case 'rate' :
$sSortParam = ' `Profiles`.`Rate` DESC, `Profiles`.`RateCount` DESC';
break;
default :
$this -> aDisplaySettings['sort'] = 'activity';
case 'activity' :
$sSortParam = ' `Profiles`.`DateLastNav` DESC';
break;
add the bold code:
// select sorting parameters ;
$sSortParam = '`Profiles`.`DateLastNav` DESC';
if ( isset($this -> aDisplaySettings['sort']) ) {
switch($this -> aDisplaySettings['sort']) {
case 'date_reg' :
$sSortParam = ' `Profiles`.`DateReg` DESC';
break;
case 'sortname' :
$sSortParam = ' `Profiles`.`NickName` ASC';
break;
case 'rate' :
$sSortParam = ' `Profiles`.`Rate` DESC, `Profiles`.`RateCount` DESC';
break;
default :
$this -> aDisplaySettings['sort'] = 'activity';
case 'activity' :
$sSortParam = ' `Profiles`.`DateLastNav` DESC';
break;
2)
and this code:
$aSortingParam = array
(
'activity' => _t( '_Latest activity' ),
'date_reg' => _t( '_FieldCaption_DateReg_View' ),
'rate' => _t( '_Rate' ),
);
add the bold code:
$aSortingParam = array
(
'activity' => _t( '_Latest activity' ),
'date_reg' => _t( '_FieldCaption_DateReg_View' ),
'sortname' => _t( '_Sort by user name' ),
'rate' => _t( '_Rate' ),
);
3)
Add a new language key: _Sort by user name
4)
Delete cache
5)
Done...