diff --git a/admin/user.php b/admin/user.php
index 9a16a17dcb1..b0bb566f73f 100644
--- a/admin/user.php
+++ b/admin/user.php
@@ -63,6 +63,12 @@
$strsearch = get_string('search');
$strshowallusers = get_string('showallusers');
+ if (empty($CFG->loginhttps)) {
+ $securewwwroot = $CFG->wwwroot;
+ } else {
+ $securewwwroot = str_replace('http:','https:',$CFG->wwwroot);
+ }
+
admin_externalpage_print_header($adminroot);
if ($confirmuser and confirm_sesskey()) {
@@ -297,11 +303,6 @@
}
$mainadmin = get_admin();
- if(empty($CFG->loginhttps)) {
- $securewwwroot = $CFG->wwwroot;
- } else {
- $securewwwroot = str_replace('http:','https:',$CFG->wwwroot);
- }
$table->head = array ("$firstname / $lastname", $email, $city, $country, $lastaccess, "", "", "");
$table->align = array ("left", "left", "left", "left", "left", "center", "center", "center");
@@ -408,7 +409,7 @@
echo "";
if (has_capability('moodle/user:create', $sitecontext)) {
- print_heading(''.get_string('addnewuser').'');
+ print_heading(''.get_string('addnewuser').'');
}
if (!empty($table)) {
print_table($table);
@@ -416,7 +417,7 @@
"user.php?sort=$sort&dir=$dir&perpage=$perpage".
"&firstinitial=$firstinitial&lastinitial=$lastinitial&search=".urlencode(stripslashes($search))."&");
if (has_capability('moodle/user:create', $sitecontext)) {
- print_heading(''.get_string('addnewuser').'');
+ print_heading(''.get_string('addnewuser').'');
}
}