';
if ($user->description && !isset($hiddenfields['description'])) {
echo '
';
if (!empty($CFG->profilesforenrolledusersonly) && !$currentuser &&
!$DB->record_exists('role_assignments', array('userid' => $user->id))) {
echo get_string('profilenotshown', 'moodle');
} else {
$user->description = file_rewrite_pluginfile_urls($user->description, 'pluginfile.php', $usercontext->id, 'user',
'profile', null);
echo format_text($user->description, $user->descriptionformat);
}
echo '
';
}
echo $OUTPUT->custom_block_region('content');
// Render custom blocks.
$renderer = $PAGE->get_renderer('core_user', 'myprofile');
$tree = core_user\output\myprofile\manager::build_tree($user, $currentuser);
echo $renderer->render($tree);
echo '
'; // Userprofile class.
echo $OUTPUT->footer();