After that last post, I think I’ll look at a nice easy one. The score for the course is stored in an element called cmi.core.score.raw. Actually, this is just one of a group of 3 elements that relate to the course score:
but only cmi.core.score.raw is mandatory, so it’s the only one that I’ll worry about.
The way that the LMS tells the course that it only supports the cmi.core.score.raw element is to return the text string ‘raw’ when the course asks for the value of cmi.core.score._children. So I modify my getValue.php code to include the following:
// cmi.core.score._children is always the same case "cmi.core.score._children": $varvalue = "raw"; break;
The initial value for cmi.core.score.raw is an empty string which is what getValue.php returns by default if an element isn’t set. So that’s all I need to do for now. Moving on …
‘cmi.core.score.raw’ this variable is not setting by set method.
Do I need to do any changes to get that and save in scormvar table?