course)) { error("Course is misconfigured"); } if (! $scorm = get_record("scorm", "id", $cm->instance)) { error("Course module is incorrect"); } } else { if (! $scorm = get_record("scorm", "id", $a)) { error("Course module is incorrect"); } if (! $course = get_record("course", "id", $scorm->course)) { error("Course is misconfigured"); } if (! $cm = get_coursemodule_from_instance("scorm", $scorm->id, $course->id)) { error("Course Module ID was incorrect"); } } require_login($course->id); $strscorms = get_string("modulenameplural", "scorm"); $strscorm = get_string("modulename", "scorm"); if ($course->category) { $navigation = "framename}\" href=\"../../course/view.php?id=$course->id\">$course->shortname -> framename}\" href=\"index.php?id=$course->id\">$strscorms ->"; } else { $navigation = "framename}\" href=\"index.php?id=$course->id\">$strscorms ->"; } $pagetitle = strip_tags("$course->shortname: $scorm->name"); add_to_log($course->id, "scorm", "pre-view", "view.php?id=$cm->id", "$scorm->id"); // // Checking if parsed scorm manifest // if ($scorm->launch == 0) { $basedir = $CFG->dataroot."/".$course->id; $scormdir = "/moddata/scorm"; $scorm->launch = scorm_parse($basedir,$scormdir.$scorm->datadir."/imsmanifest.xml",$scorm->id); set_field("scorm","launch",$scorm->launch,"id",$scorm->id); } // // Print the page header // if (!$cm->visible and !isteacher($course->id)) { print_header($pagetitle, "$course->fullname", "$navigation $scorm->name", "", "", true, update_module_button($cm->id, $course->id, $strscorm), navmenu($course, $cm)); notice(get_string("activityiscurrentlyhidden")); } else { print_header($pagetitle, "$course->fullname","$navigation framename}\" href=\"$ME?id=$cm->id\" title=\"$scorm->summary\">$scorm->name", "", "", true, update_module_button($cm->id, $course->id, $strscorm), navmenu($course, $cm)); if (isteacher($course->id)) { if ($sco_users = get_records_select("scorm_sco_users", "scormid='$scorm->id' GROUP BY userid")) { echo "
"; } else { echo "".get_string("noreports","scorm")."
"; } } // Print the main part of the page print_heading($scorm->name); print_simple_box(text_to_html($scorm->summary), "CENTER"); if (isguest()) { print_heading(get_string("guestsno", "scorm")); print_footer($course); exit; } echo "".get_string("coursestruct","scorm")." |
---|
\n
|