Permalink
Browse files

Tidied up headers of user/edit.php

  • Loading branch information...
martin
martin committed Aug 14, 2002
1 parent 3be1715 commit 7cbb4c96db50a4c7b07905dfa078b99320c72426
Showing with 21 additions and 9 deletions.
  1. +1 −0 lang/en/moodle.php
  2. +20 −9 user/edit.php
View
@@ -222,6 +222,7 @@
\$a->signoff\n";
$string[newpicture] = "New picture";
+$string[newuser] = "New user";
$string[newusers] = "New users";
$string[newsitem] = "news item";
$string[newsitems] = "news items";
View
@@ -149,16 +149,27 @@
$editmyprofile = get_string("editmyprofile");
$participants = get_string("participants");
- if ($course->category) {
- print_header("$course->fullname: $editmyprofile", "$course->fullname: $editmyprofile",
- "<A HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">$course->shortname</A>
- -> <A HREF=\"index.php?id=$course->id\">$participants</A>
- -> <A HREF=\"view.php?id=$user->id&course=$course->id\">$user->firstname $user->lastname</A>
- -> $editmyprofile", "");
+ if ($user->firstname and $user->lastname) {
+ $userfullname = "$user->firstname $user->lastname";
+ if ($course->category) {
+ print_header("$course->fullname: $editmyprofile", "$course->fullname: $editmyprofile",
+ "<A HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">$course->shortname</A>
+ -> <A HREF=\"index.php?id=$course->id\">$participants</A>
+ -> <A HREF=\"view.php?id=$user->id&course=$course->id\">$userfullname</A>
+ -> $editmyprofile", "");
+ } else {
+ print_header("$course->fullname: $editmyprofile", "$course->fullname",
+ "<A HREF=\"view.php?id=$user->id&course=$course->id\">$userfullname</A>
+ -> $editmyprofile", "");
+ }
} else {
+ $userfullname = get_string("newuser");
+ $straddnewuser = get_string("addnewuser");
+
+ $stradministration = get_string("administration");
print_header("$course->fullname: $editmyprofile", "$course->fullname",
- "<A HREF=\"view.php?id=$user->id&course=$course->id\">$user->firstname $user->lastname</A>
- -> $editmyprofile", "");
+ "<A HREF=\"$CFG->wwwroot/admin\">$stradministration</A> ->
+ $straddnewuser", "");
}
$teacher = strtolower($course->teacher);
@@ -167,7 +178,7 @@
}
print_simple_box_start("center", "", "$THEME->cellheading");
- print_heading( get_string("userprofilefor", "", "$user->firstname $user->lastname") );
+ print_heading( get_string("userprofilefor", "", "$userfullname") );
include("edit.html");
print_simple_box_end();
print_footer($course);

0 comments on commit 7cbb4c9

Please sign in to comment.