dirroot.DIRECTORY_SEPARATOR.'mod'.DIRECTORY_SEPARATOR.'hotpot'.DIRECTORY_SEPARATOR.'lib.php' ); // set default values in form fields, if necessary set_form_fields($form); // commonly used array of : '; helpbutton("writing", get_string("helpwriting"), "moodle", true, true); echo '
'; if (isset($usehtmleditor) && $usehtmleditor) { helpbutton("richtext", get_string("helprichtext"), "moodle", true, true); echo '
'; } else { helpbutton("text", get_string("helptext"), "moodle", true, true); echo '
'; emoticonhelpbutton("form", "description"); echo '
'; } ?>
summary); } else { // Moodle 1.1.1 (original size was rows="5" cols="50") print ''; } ?> : timeopen and $course->format == "weeks") { $form->timeopen= $course->startdate + (($form->section - 1) * 608400); } print_date_selector("openday", "openmonth", "openyear", $form->timeopen); print ' - '; print_time_selector("openhour", "openminute", $form->timeopen); helpbutton("timeopen", get_string("quizopen","quiz"), "quiz"); ?> : timeclose and $course->format == "weeks") { $form->timeclose= $course->startdate + (($form->section) * 608400); } print_date_selector("closeday", "closemonth", "closeyear", $form->timeclose); print ' - '; print_time_selector("closehour", "closeminute", $form->timeclose); helpbutton("timeopen", get_string("quizclose","quiz"), "quiz"); ?> : id==$site->id) { $id = $site->id; $location = HOTPOT_LOCATION_SITEFILES; } else { $id = "'+(getObjValue(this.form.location)==".HOTPOT_LOCATION_SITEFILES."?".$site->id.":".$course->id.")+'"; $location = ''; } } else { // ordinary teacher or content creator $id = $course->id; $location = HOTPOT_LOCATION_COURSEFILES; } if (array_key_exists($location, $HOTPOT_LOCATION)) { echo ''; echo ''.$HOTPOT_LOCATION[$location].'   '; } else { // admin can select from "site" or "course" files choose_from_menu($HOTPOT_LOCATION, "location", "$form->location", ""); } if (function_exists("button_to_popup_window")) { // use javascript to extract wdir from the reference field $wdir = "'+getDir(getObjValue(this.form.reference))+'"; // set button url depending on Moodle version if ($CFG->version < 2004083125) { // version may need refining // up to and including Moodle 1.4.1 $url = "/mod/resource/coursefiles.php?id=$id&wdir=$wdir"; } else { // Moodle 1.4.2 and beyond $url = "/files/index.php?id=$id&wdir=$wdir&choose=form.reference"; } $strchooseafile = get_string("chooseafile", "resource"); button_to_popup_window ($url, 'coursefiles', $strchooseafile, 500, 750, $strchooseafile); } ?> : reference\"> "; } else if (function_exists("get_directory_list")) { // Moodle 1.1 (and perhaps some others) $dirs = get_directory_list("$CFG->dataroot/$course->id"); $options = array(); foreach ($dirs as $dir) { $options["$dir"] = $dir; } choose_from_menu ($options, "reference", $form->reference); } else { // a very old Moodle (may be none left :-) echo "reference\"> "; } echo '
'; hotpot_print_show_links($form->course, $form->location, $form->reference, '', '   ', true); ?> : navigation", ""); helpbutton("navigation", get_string("navigation","hotpot"), "hotpot"); ?> : outputformat", ""); helpbutton("outputformat", get_string("outputformat","hotpot"), "hotpot"); ?> : forceplugins", ""); helpbutton("forceplugins", get_string("forceplugins","hotpot"), "hotpot"); ?> : shownextquiz", ""); helpbutton("shownextquiz", get_string("shownextquiz","hotpot"), "hotpot"); ?> : review", ""); helpbutton("review", get_string("allowreview","quiz"), "quiz"); ?> : =1; $i--) { $options[$i] = $i; } $options[0] = get_string("nograde"); choose_from_menu($options, "grade", "$form->grade", ""); helpbutton("maxgrade", get_string("maximumgrade"), "quiz"); ?> : grademethod", ""); helpbutton("grademethod", get_string("grademethod","quiz"), "quiz"); ?> : get_string("attemptsunlimited", "quiz"), 1 => '1 '.strtolower(get_string("attempt", "quiz")) ); for ($i=2; $i<=10; $i++) { $options[$i] = "$i ".strtolower(get_string("attempts", "quiz")); } choose_from_menu($options, "attempts", "$form->attempts", ""); helpbutton("attempts", get_string("attemptsallowed","quiz"), "quiz"); ?> : : sesskey)) { ?> ">   " /> $fieldname)) { $form->$fieldname = $defaultvalue; } } ?>