Show the user's name in the title and header
This commit is contained in:
+3
-3
@@ -61,7 +61,7 @@ if (!$currentuser &&
|
||||
!has_coursecontact_role($userid)) {
|
||||
// Course managers can be browsed at site level. If not forceloginforprofiles, allow access (bug #4366)
|
||||
$struser = get_string('user');
|
||||
$PAGE->set_title("$SITE->shortname: $struser");
|
||||
$PAGE->set_title("$SITE->shortname: $struser"); // Do not leak the name
|
||||
$PAGE->set_heading("$SITE->shortname: $struser");
|
||||
$PAGE->set_url('/user/profile.php', array('id'=>$userid));
|
||||
$PAGE->navbar->add($struser);
|
||||
@@ -105,8 +105,8 @@ $params = array('id'=>$userid);
|
||||
$PAGE->set_url('/user/profile.php', $params);
|
||||
$PAGE->blocks->add_region('content');
|
||||
$PAGE->set_subpage($currentpage->id);
|
||||
$PAGE->set_title("$SITE->shortname: $strpublicprofile");
|
||||
$PAGE->set_heading("$SITE->shortname: $strpublicprofile");
|
||||
$PAGE->set_title(fullname($user).": $strpublicprofile");
|
||||
$PAGE->set_heading(fullname($user).": $strpublicprofile");
|
||||
|
||||
if (!$currentuser) {
|
||||
$PAGE->navigation->extend_for_user($user);
|
||||
|
||||
Reference in New Issue
Block a user