dirroot.'/mod/scorm/locallib.php'); if (!isset($form->name)) { $form->name = ''; } if (!isset($form->reference)) { $form->reference = ''; } if (!isset($form->summary)) { $form->summary = ''; } if (!isset($form->launch)) { $form->launch = ''; } if (!isset($form->skipview)) { $form->skipview = 1; } if (!isset($form->auto)) { $form->auto = ''; } if (!isset($form->popup)) { $form->popup = 0; } if (!isset($form->datadir)) { $form->datadir = ''; } if (!isset($form->maxgrade)) { $form->maxgrade = ''; } if (!isset($form->grademethod)) { $form->grademethod = 0; $form->whatgrade = 0; } else { $form->whatgrade = intval($form->grademethod / 10); $form->grademethod = $form->grademethod % 10; } if (!isset($form->maxattempt)) { $form->maxattempt = 1; } if (!isset($form->hidebrowse)) { $form->hidebrowse = 0; } if (!isset($form->hidetoc)) { $form->hidetoc = 0; } if (!isset($form->hidenav)) { $form->hidenav = 0; } if (!isset($form->width)) { $form->width = $CFG->scorm_framewidth; } if ((strpos($form->width,'%') === false) && ($form->width <= 100)) { $form->width .= '%'; } if (!isset($form->height)) { $form->height = $CFG->scorm_frameheight; } if ((strpos($form->height,'%') === false) && ($form->height <= 100)) { $form->height .= '%'; } if (!isset($form->options) || empty($form->options)) { $form->options = $stdoptions; } $options = explode(',',$form->options); $window = new stdClass(); foreach ($options as $option) { list($element,$value) = explode('=',$option); $element = trim($element); $window->$element = trim($value)==1?'checked':''; } if (!isset($form->pkgtype)) { $form->pkgtype = ''; } $scormid = ''; if (!empty($form->instance)) { $scormid = '&instance='.$form->instance; } $datadir = ''; if (!empty($form->datadir)) { $datadir = '&datadir='.$form->datadir; } $sessionkey = ''; if (!empty($form->sesskey)) { $sessionkey = '&sesskey='.$form->sesskey; } $strfilename = get_string('coursepacket', 'scorm'); $strchooseafile = get_string('chooseapacket', 'scorm'); $strbrowserepository = get_string('browserepository', 'scorm'); $striframe = get_string('iframe', 'scorm'); $striframedisplay = get_string('iframedisplay', 'scorm'); $strnewwindow = get_string('popup', 'scorm'); $strnewwindowopen = get_string('popupopen', 'scorm'); $strheight = get_string('height', 'scorm'); $strwidth = get_string('width', 'scorm'); $strresizable = get_string('resizable', 'scorm'); $strscrollbars = get_string('scrollbars', 'scorm'); $strdirectories = get_string('directories', 'scorm'); $strlocation = get_string('location', 'scorm'); $strmenubar = get_string('menubar', 'scorm'); $strtoolbar = get_string('toolbar', 'scorm'); $strstatus = get_string('statusbar', 'scorm'); ?>