mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 22:08:20 +01:00
Patched the auto-continue feature
This commit is contained in:
parent
fe6571366c
commit
de8595db91
@ -28,10 +28,10 @@ function SCORMapi() {
|
||||
cmi.core.credit = "credit";
|
||||
cmi.core.lesson_status = "<?php echo $sco_user->cmi_core_lesson_status; ?>";
|
||||
cmi.core.exit = "<?php echo $sco_user->cmi_core_exit ?>";
|
||||
cmi.core.entry = "<?php if ($sco_user->cmi_core_lesson_status=="not attempted")
|
||||
cmi.core.entry = "<?php if ($sco_user->cmi_core_lesson_status=='not attempted')
|
||||
echo 'ab-initio';
|
||||
else
|
||||
if ($sco_user->cmi_core_lesson_status!="completed")
|
||||
if ($sco_user->cmi_core_lesson_status!='completed')
|
||||
echo 'resume';
|
||||
else
|
||||
echo '';?>";
|
||||
@ -211,10 +211,10 @@ function SCORMapi() {
|
||||
<?php
|
||||
if ($scorm->auto) {
|
||||
if ($sco != $last) {
|
||||
print "setTimeout('".$navObj."document.navform.next.click();',500);\n";
|
||||
echo "setTimeout('".$navObj."document.navform.next.click();',500);\n";
|
||||
} else {
|
||||
print "exitloc = '".$CFG->wwwroot."/mod/scorm/view.php?id=$cm->id';\n";
|
||||
print "setTimeout('top.location = exitloc;',500);\n";
|
||||
echo "exitloc = '".$CFG->wwwroot."/mod/scorm/view.php?id=".$cm->id."';\n";
|
||||
echo "setTimeout('top.location = exitloc;',500);\n";
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
@ -46,10 +46,12 @@ function scorm_add_instance($scorm) {
|
||||
}
|
||||
}
|
||||
$scorm->popup = implode(',', $optionlist);
|
||||
$scorm->auto = '0';
|
||||
|
||||
|
||||
if ($scorm->popup != "")
|
||||
if ($scorm->popup != "") {
|
||||
$scorm->popup .= ',location=0,menubar=0,toolbar=0';
|
||||
$scorm->auto = '0';
|
||||
}
|
||||
|
||||
return insert_record("scorm", $scorm);
|
||||
}
|
||||
@ -75,11 +77,11 @@ function scorm_update_instance($scorm) {
|
||||
}
|
||||
}
|
||||
$scorm->popup = implode(',', $optionlist);
|
||||
$scorm->auto = '0';
|
||||
|
||||
if ($scorm->popup != "")
|
||||
if ($scorm->popup != "") {
|
||||
$scorm->popup .= ',location=0,menubar=0,toolbar=0';
|
||||
|
||||
$scorm->auto = '0';
|
||||
}
|
||||
return update_record("scorm", $scorm);
|
||||
}
|
||||
|
||||
|
@ -61,6 +61,7 @@
|
||||
<input type="hidden" name=datadir value="<?php p($form->datadir) ?>">
|
||||
<input type="hidden" name=launch value="<?php p($form->launch) ?>">
|
||||
<input type="hidden" name=popup value="<?php p($form->popup) ?>">
|
||||
<input type="hidden" name=auto value="<?php p($form->auto) ?>">
|
||||
<input type="hidden" name=section value="<?php p($form->section) ?>">
|
||||
<input type="hidden" name=module value="<?php p($form->module) ?>">
|
||||
<input type="hidden" name=modulename value="<?php p($form->modulename) ?>">
|
||||
|
Loading…
x
Reference in New Issue
Block a user