MDL-41665 scorm lib.php: Rewriting using html_writer