![]() |
Course Development : Using LectoraLectora is a powerful authoring tool for web-based training that's widely used in mid-sized to larger enterprises. The following note describes how it can easily be used to develop courses in LM-Light format. Note: If you'd like to look at the files as you follow through this technical note, you can download them all as a 44kB zip file from [this link]. You can also use the .awt file included in the zip file to cut and paste elements to the course that you're working on.
The CourseWe're going to look at a very simple course that consists of 3 pages, and a 2 question multiple-choice mastery test.
The Initialization TagWe're going to start by inserting the initialization tag (require "LM-Light.php";) on every page in the title. This is a simple operation due to the way that Lectora allows objects to be inherited. Start by selecting the title object - in this case "'Demo01' - and then click on the 'Add External HTML' button on the top bar. This will pop open the 'External HTML Object Properties'.
Choose the 'Top of File Scripting' object type, and enter the following text into the 'Custom HTML' field.
This code will now be inserted at the top of every page that Lectora generates. The Bookmark TagWe follow the same basic procedure to insert the bookmarking tag. Start by selecting the initialization tag that we just added to the title. By selcting this object when we insert the bookmark tag, we make sure that the bookmark tag follows after the initialization tag. Then click on the 'Add External HTML' button on the top bar.
Once again, we choose the 'Top of File Scripting' object type, and then enter the following text into the 'Custom HTML' field.
This code will now be inserted at the top of every page that Lectora generates imediately after the initialization tag. However, we have one more thing to do. We don't want to bookmark the test/assessment questions, or the assessment result pages. So, double-click on the 'Final Assessment' object - the 'Test Properties' dialog should open as shown.
Choose the 'Inherit' tab, and move the LMsetBookmark into the right hand column. Any pages within the 'Final Assessment' section will no longer have the 'LMsetBookmark()' code inserted in the page when the course is compiled. Repeat the process for the 'Assessment Results' object. The Register Test Attempt TagWe want to add a register test attempt tag to the first page of the assessment test. We follow exactly the same procedure as above starting with selecting the 'Test Page 1' object and clicking on the 'Add External HTML' button on the top bar. In the 'External HTML Object Properties' dialog, we choose the 'Top of File Scripting' object type, and enter the following text into the 'Custom HTML' field.
The Course Complete TagWhen a student arrives at the 'Assessment Passed' page, we want to flag the course as complete. Once again, we use an 'External HTML Object' to do this exactly as before. We start by selecting the 'Assessment Passed' object, click on the 'Add External HTML' button on the top bar, and then in the 'External HTML Object Properties' dialog, we choose the 'Top of File Scripting' object type, and enter the following text into the 'Custom HTML' field.
Transferring the Test ScoreThe last part of the development is slightly more complicated. We want to transfer the test score from the Lectora-generated course to the LMS when the student reaches either the assessment passed, or the assessment failed pages. We're going to do this by using Lectora's 'Submit Form' action. Start by selecting the 'Assessment Results' object so that that actions are inherited by both the 'Assessment Passed' and the 'Assessment Failed' page. Then click on the 'Form' button on the top bar.
In the 'Form Properties' dialog, specify that you're going to submit the form to a 'CGI' program using the post method, and enter the name of the file that will handle the submission (we'll create that file in a few minutes). Before you leave the 'Form Properties' dialog, choose the 'Parameters' tab.
The LM-Light library is expecting to see a variable called 'LMtestScore' being passed across. However, Lectora stores the test score in a variable called [the name of your test]_Score - in this case, Final_Assessment_Score. So we can use the 'Parameters' tab to transfer the value from the Lectora variable (Final_Assessment_Score) to a variable that LM-Light can understand (LMtestScore) as shown in the figure above. We now need to make the course submit the form when one of the assessment results pages is viewed. To do this, we select the 'Assessment Results' object so that that actions are inherited by both the 'Assessment Passed' and the 'Assessment Failed' page. Then we click on the 'Add Action' button on the top bar.
We set the action to submit the form that we've just created when the course displays either the 'Assessment Failed' or 'Assessment Passed' pages. Now we simply need to create the HTML file that will handle the form submission. To do this, go to the 'extern' subdirectory/folder in the course folder, and create a blank file called 'setScore.html'. Then, using a text editor, enter the following code into the setScore.html file, and save it.
Finally, we need to include the HTML file into the course when it's compiled. Select the top level object, double click on it, and choose the 'Additional Files' tab. find the HTML file that you've just created, and add it to the list. This file will now be included in the course when you compile it.
Compiling The CourseLectora has a variety of formats in which it can compile a course. Here, we choose the simplest - 'Publish to HTML' - and also take advantage of the way that Lectora can automatically create a zip file for transfer to the LMS.
Summary of StepsHere's a short summary of the steps involved in the process.
Final ThoughtsAlthough the steps described above may seem a little long-winded, you'll quickly find that Lectora allows you to do a lot of cutting and pasting. So, once you 've set up one course in this way, it's a fairly simple matter to cut and paste the various objects from course-to-course thus saving you a lot of work.
|
|