From: defacer Date: Thu, 27 Jan 2005 23:56:46 +0000 (+0000) Subject: Bugfix: when configuring a block in the site index, the site name was X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=e355a2d304b52cb4ec7ca408959865535187d5d3;p=moodle.git Bugfix: when configuring a block in the site index, the site name was being displayed twice in the breadcrumbs. --- diff --git a/lib/pagelib.php b/lib/pagelib.php index 098372ffba..88e6bd5769 100644 --- a/lib/pagelib.php +++ b/lib/pagelib.php @@ -341,7 +341,13 @@ class page_course extends page_base { $title = str_replace($search, $replace, $title); } - $breadcrumbs = array($this->courserecord->shortname => $CFG->wwwroot.'/course/view.php?id='.$this->courserecord->id); + if($this->courserecord->id == SITEID) { + $breadcrumbs = array(); + } + else { + $breadcrumbs = array($this->courserecord->shortname => $CFG->wwwroot.'/course/view.php?id='.$this->courserecord->id); + } + if(!empty($morebreadcrumbs)) { $breadcrumbs = array_merge($breadcrumbs, $morebreadcrumbs); }