Index: tablelib.php =================================================================== RCS file: /cvsroot/moodle/moodle/lib/tablelib.php,v retrieving revision 1.24.2.5 diff -u -r1.24.2.5 tablelib.php --- tablelib.php 22 May 2008 02:33:56 -0000 1.24.2.5 +++ tablelib.php 2 Apr 2009 05:25:56 -0000 @@ -658,8 +658,17 @@ $fsortorder = get_string('asc'); $lsortorder = get_string('asc'); } - $this->headers[$index] = ''.get_string('firstname').get_accesshide(get_string('sortby').' '.get_string('firstname').' '.$fsortorder).' '.$icon_sort_first.' / '. - ''.get_string('lastname').get_accesshide(get_string('sortby').' '.get_string('lastname').' '.$lsortorder).' '.$icon_sort_last; + if (($CFG->fullnamedisplay == 'firstname lastname') or + ($CFG->fullnamedisplay == 'firstname') or + ($CFG->fullnamedisplay == 'language' and $fullnamelanguage == 'firstname lastname' )) { + $this->headers[$index] = ''.get_string('firstname').get_accesshide(get_string('sortby').' '.get_string('firstname').' '.$fsortorder).' '.$icon_sort_first.' / '. + ''.get_string('lastname').get_accesshide(get_string('sortby').' '.get_string('lastname').' '.$lsortorder).' '.$icon_sort_last; + } else { // ($CFG->fullnamedisplay == 'language' and $fullnamelanguage == 'lastname firstname') + ($CFG->fullnamedisplay == 'firstname') or + ($CFG->fullnamedisplay == 'language' and $fullnamelanguage == 'firstname lastname' )) { + $this->headers[$index] = ''.get_string('lastname').get_accesshide(get_string('sortby').' '.get_string('lastname').' '.$lsortorder).' '.$icon_sort_last.' / '. + ''.get_string('firstname').get_accesshide(get_string('sortby').' '.get_string('firstname').' '.$fsortorder).' '.$icon_sort_first; + } } break;