I just tried to save my quiz and moodle is giving me this error.
This module is missing important code! (D:\Web Sites\MC Online/mod//lib.php
Continue
Any ideas?? I haven't done anything to the moodle files .
Bump!
Anyone out there?
I'm guessing nodody else has received this error before? If that is the reason for the lack of response, I have another question. Because I can't figure out how to fix this problem and I'm running 1.3, how would I upgrade my quiz module (as this would be the only way to fix the problem I'm guessing?). Would I simply reupload an unziped quiz module from the 1.3 tgz I have, or should I upgrade the quiz module to a new version of moodle (1.3.1, 1.3.3 etc), and if I should do that, would I simply download the 1.3.3 version and use that quiz module as the quiz module on the download page is only good for 1.4 dev.
Looking forward to your responses!
Yeah, somewhat broken as it will not save. Had a thought though. Last week I the admin of the box moodle is hosted on made some changes to php config file for a session issue we were having with KnowledgeTree (DMS system that Moodle should use!), the change helped with KnowledgeTree but may be what is causing my current error? This is what its in the MOD.php that it bringing up the error.
require_login();
##Could it be possible that the vars are not being stored right because of this change we made in the php config file? Thus causing the error that is bolded below?
if (isset($SESSION->modform)) { // Variables are stored in the session
$mod = $SESSION->modform;
unset($SESSION->modform);
} else {
$mod = (object)$_POST;
}
if (isset($cancel)) {
if (!empty($SESSION->returnpage)) {
$return = $SESSION->returnpage;
unset($SESSION->returnpage);
redirect($return);
} else {
redirect("view.php?id=$mod->course");
}
}
if (isset($_POST["course"])) { // add or update form submitted
if (!$course = get_record("course", "id", $mod->course)) {
error("This course doesn't exist");
}
if (!isteacheredit($course->id)) {
error("You can't modify this course!");
}
$modlib = "$CFG->dirroot/mod/$mod->modulename/lib.php";
if (file_exists($modlib)) {
include_once($modlib);
} else {
error("This module is missing important code! ($modlib)");