mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 08:26:37 +02:00
Breadcrumbs: course admin changes
- Modified to use build_navigation() for breadcrumb generation. Author: Matt Clarkson <mattc@catalyst.net.nz>
This commit is contained in:
parent
d91f99a655
commit
e1d2eb00e2
2 changed files with 20 additions and 12 deletions
|
@ -646,7 +646,6 @@
|
|||
} else {
|
||||
$pageheading = get_string("addinganew", "moodle", $fullmodulename);
|
||||
}
|
||||
$strnav = '';
|
||||
|
||||
$CFG->pagepath = 'mod/'.$module->name;
|
||||
if (!empty($type)) {
|
||||
|
@ -673,9 +672,11 @@
|
|||
$focuscursor = "form.name";
|
||||
}
|
||||
|
||||
print_header_simple($streditinga, '',
|
||||
"<a href=\"$CFG->wwwroot/mod/$module->name/index.php?id=$course->id\">$strmodulenameplural</a> ->
|
||||
$strnav $streditinga", $focuscursor, "", false);
|
||||
$crumbs[] = array('name' => $strmodulenameplural, 'link' => "$CFG->wwwroot/mod/$module->name/index.php?id=$course->id", 'type' => 'activity');
|
||||
$crumbs[] = array('name' => $streditinga, 'link' => '', 'type' => 'action');
|
||||
$navigation = build_navigation($crumbs, $course);
|
||||
|
||||
print_header_simple($streditinga, '', $navigation, $focuscursor, "", false);
|
||||
|
||||
if (!empty($cm->id)) {
|
||||
$context = get_context_instance(CONTEXT_MODULE, $cm->id);
|
||||
|
|
|
@ -56,7 +56,6 @@
|
|||
} else {
|
||||
$pageheading = get_string("addinganew", "moodle", $fullmodulename);
|
||||
}
|
||||
$strnav = '';
|
||||
|
||||
$CFG->pagepath = 'mod/'.$module->name;
|
||||
if (!empty($type)) {
|
||||
|
@ -110,7 +109,9 @@
|
|||
} else {
|
||||
$pageheading = get_string("updatinga", "moodle", $fullmodulename);
|
||||
}
|
||||
$strnav = "<a href=\"$CFG->wwwroot/mod/$module->name/view.php?id=$cm->id\">".format_string($form->name,true)."</a> ->";
|
||||
|
||||
$crumbsinstancename = array('name' => format_string($form->name,true), 'link' => "$CFG->wwwroot/mod/$module->name/view.php?id=$cm->id", 'type' => 'activityinstance');
|
||||
|
||||
$CFG->pagepath = 'mod/'.$module->name;
|
||||
if (!empty($type)) {
|
||||
$CFG->pagepath .= '/'.$type;
|
||||
|
@ -297,9 +298,15 @@
|
|||
$streditinga = get_string("editinga", "moodle", $fullmodulename);
|
||||
$strmodulenameplural = get_string("modulenameplural", $module->name);
|
||||
|
||||
print_header_simple($streditinga, '',
|
||||
"<a href=\"$CFG->wwwroot/mod/$module->name/index.php?id=$course->id\">$strmodulenameplural</a> ->
|
||||
$strnav $streditinga", $mform->focus(), "", false);
|
||||
$crumbs[] = array('name' => $strmodulenameplural, 'link' => "$CFG->wwwroot/mod/$module->name/index.php?id=$course->id", 'type' => 'activity');
|
||||
if (isset($crumbsinstancename)) {
|
||||
$crumbs[] = $crumbsinstancename;
|
||||
}
|
||||
$crumbs[] = array('name' => $streditinga, 'link' => '', 'type' => 'title');
|
||||
|
||||
$navigation = build_navigation($crumbs, $course);
|
||||
|
||||
print_header_simple($streditinga, '', $navigation, $mform->focus(), "", false);
|
||||
|
||||
if (!empty($cm->id)) {
|
||||
$context = get_context_instance(CONTEXT_MODULE, $cm->id);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue