--- /Applications/MAMP/htdocs/m22/course/editcategory_orig.php 2012-05-10 15:43:26.000000000 +0200 +++ /Applications/MAMP/htdocs/m22/course/editcategory.php 2012-05-10 15:42:49.000000000 +0200 @@ -136,7 +136,10 @@ // where the user thinks they are. // The big prolem here is that the course management page is a common page // for both editing users and common users. - $PAGE->settingsnav->get('root')->get('courses')->get('coursemgmt')->make_active(); + if ($PAGE->settingsnav->get('root')) { + $PAGE->settingsnav->get('root')->get('courses')->get('coursemgmt')->make_active(); + } + //$PAGE->settingsnav->get('root')->get('courses')->get('coursemgmt')->make_active(); } catch (Exception $ex) { // Failing that we'll override the URL, not as accurate and chances are things // won't be 100% correct all the time but should work most times.