]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-17458 fixed headers used during installation
authorskodak <skodak>
Sun, 1 Feb 2009 17:45:32 +0000 (17:45 +0000)
committerskodak <skodak>
Sun, 1 Feb 2009 17:45:32 +0000 (17:45 +0000)
admin/index.php
admin/upgradesettings.php
lib/adminlib.php
lib/weblib.php
user/editadvanced.php

index efdea060a0a7f657cfce422dbb803e3601935756..c6a0c7d736d7c7bb1fe9a001f2e6d059394e31d4 100644 (file)
 
         $strdatabasesetup = get_string("databasesetup");
         $navigation = build_navigation(array(array('name'=>$strdatabasesetup, 'link'=>null, 'type'=>'misc')));
-
-        print_header($strinstallation, $strinstallation, $navigation,
-                    "", upgrade_get_javascript(), false, "&nbsp;", "&nbsp;");
+        print_header($strinstallation, $strinstallation, $navigation, "", upgrade_get_javascript(), false, "&nbsp;", "&nbsp;");
 
         if (!$DB->setup_is_unicodedb()) {
             if (!$DB->change_db_encoding()) {
index 81f5cdd11f5bbf3606f630388000c70e23c6e1e7..1ab426ae11469ba5c1aabe367705e659d7621e8f 100644 (file)
@@ -49,7 +49,9 @@ if (!empty($adminroot->errors)) {
 // to modify them
 admin_externalpage_print_header($focus);
 
-print_box(get_string('upgradesettingsintro','admin'), 'generalbox');
+if (!empty($SITE->fullname) and !empty($SITE->shortname)) {
+    print_box(get_string('upgradesettingsintro','admin'), 'generalbox');
+}
 
 echo '<form action="upgradesettings.php" method="post" id="adminsettings">';
 echo '<div>';
index 8ce7df206c5e14fff311a2da5d42c12f21b575ae..c91d39dceb26a842545705b4dc7e81066d3e6216 100644 (file)
@@ -4039,7 +4039,7 @@ function admin_externalpage_print_header($focus='') {
 
     define('ADMIN_EXT_HEADER_PRINTED', 'true');
 
-    if (!empty($SITE->fullname)) {
+    if (!empty($SITE->fullname) and !empty($SITE->shortname)) {
         $pageblocks = blocks_setup($PAGE);
 
         $preferred_width_left = bounded_number(BLOCK_L_MIN_WIDTH,
@@ -4085,7 +4085,10 @@ function admin_externalpage_print_header($focus='') {
             }
         }
     } else {
-        print_header();
+        $strinstallation = get_string('installation', 'install');
+        $strsettings = get_string('settings');
+        $navigation = build_navigation(array(array('name'=>$strsettings, 'link'=>null, 'type'=>'misc')));
+        print_header($strinstallation, $strinstallation, $navigation, "", "", false, "&nbsp;", "&nbsp;");
     }
 }
 
index 5723e8e48180cb1279a319d8593e198c9e507412..dd31ad8f7aa234894d4fd5ac34db818d0e8df8fb 100644 (file)
@@ -3707,7 +3707,7 @@ function build_navigation($extranavlinks, $cm = null) {
     $navlinks = array();
 
     //Site name
-    if ($SITE) {
+    if (!empty($SITE->shortname)) {
         $navlinks[] = array(
                 'name' => format_string($SITE->shortname),
                 'link' => "$CFG->wwwroot/",
index f765a65d7e0c651ece0d30960d9f1baf1dcf1286..dc254f74e410efa34fc2e9e80f34a067637f30aa 100644 (file)
             print_heading($userfullname);
         }
     } else if (!empty($USER->newadminuser)) {
+        $strinstallation = get_string('installation', 'install');
         $strprimaryadminsetup = get_string('primaryadminsetup');
-        print_header($strprimaryadminsetup, $strprimaryadminsetup);
+        $navigation = build_navigation(array(array('name'=>$strprimaryadminsetup, 'link'=>null, 'type'=>'misc')));
+        print_header($strinstallation, $strinstallation, $navigation, "", "", false, "&nbsp;", "&nbsp;");
         print_simple_box(get_string('configintroadmin', 'admin'), 'center', '50%');
         echo '<br />';
     } else {