In the previous chapter, we learned that the Digital Teacher web lesson files are automatically generated from the Digital Teacher authoring program. The generated files are:
For the .HTM type lesson - myLesson.HTM - myLesson.JS For the .ASP type lesson - myLesson.ASP - myLesson.JS (Not generated when the lesson content is read from myLesson.WSD) - myLesson.WSD
When the files are created, we will want to preview the lesson on our local PC before we finally publish (upload) them on the Web.
Every time we create a web-based lesson from the Digital Teacher authoring program, we get a prompt that asks us if we like to preview the lesson on our browser. If we say Yes, Digital Teacher automatically loads a login page for us so that we can go through the login process to preview the generated web lesson page. If we choose No, we will have to open the lesson page manually.
To open an .HTM type lesson manually, we either
To open an .ASP type lesson manually,
Also, note that every Digital Teacher web lesson is composed of multiple files. In addition to the two (or three) main lesson files, which are automatically generated by the Digital Teacher authoring program, we need to have other supporting files placed in the proper locations. We will discuss it in more details in the next chapter - Chapter 5: Publishing Web Lessons.
As stated in the previous topic, when the Digital Teacher authoring program completes generating a web lesson, it will ask us if we want to preview the generated lesson immediately. If we choose Yes, the program will automatically load an appropriate login page.
The Digital Teacher web application comes with two example login files.
- dtLogin.htx for login to the .HTM type lesson, and - dtLoginNT.htm for the .ASP type lesson
Depending on which type of lesson we generate, one of these login files is automatically loaded.
dtLogin.HTX is not a login file itself. It is a template file, from which an actual login file for each .HTM type lesson is automatically created.
When we generate an. HTM lesson and want to preview it immediately, the Digital Teacher authoring program creates a login file using dtLogin.HTX as a template, and loads the login file on our browser.
The created login file is always placed in the same directory as the lesson file. For example, if we export a book titled "myExam" to a .HTM type web lesson in the c:\dteacher\Lesson\ directory,
we will have
- c:\dteacher\Lesson\myExam.htm (the lesson file) - c:\dteacher\Lesson\myExam.js (the content file) - c:\dteacher\Lesson\myExam_login.html (the login file)
Note: The file dtLogin.htx is located in the Digital Teacher program folder. This file must neither be removed from this location nor be renamed. However, you can replace this file with your own as long as the file name is not changed.
The file dtLoginNT.htm is provided as a component of the Digital Teacher web application, and serves as the login page for every lessons created in the ASP type.
In order for the Digital Teacher Authoring Program to load this login file automatically, its location must be known to the program in advance - meaning that we must have specified its path information.
One thing we must pay special attention here is that the file must be located in a web folder on our personal web server. Why? If you remember, the .ASP type lesson can only be loaded from the web server. That means that in order for us to access the ASP type lesson page locally, the login page must be loaded from our personal web server in the first place assuming that the server is already installed on our PC.
We will discuss how to install the PWS in details in
Chapter 12: Installing Personal Web Server.
Note: When the browser is loaded on our PWS, it may display a message "No connection to the Internet is currently available..." If you get this message, simply click on the Try Again button.
In order for the Digital Teacher authoring program to load dtLoginNT.htm, the program must know the file location. Also, the file must be loaded from our Personal Web Server.
The figure below shows us how we can specify the location of dtLoginNT.htm.
First, we must specify our web folder location on our PC. The web folder is the directory on our web site, where we store our web pages to be seen by the world-wide audience on the Internet. Since a web folder represents an actual (physical) directory location on the disk inside our server computer, it is "virtual."
In order to view web pages (.ASP pages) on our local PC, we need to simulate the Web.
To do so, we must already have installed a web server (Personal Web Server) and created
a directory. The example in the figure shows us that we have created it in the
physical directory c:\InetPub\wwwroot\dteacher\, and set its vitual folder path to
http://pavilion/digitalteacher/.
The "pavilion" happens to be the name of our PC, and the "digitalteacher" is our virtual web root folder, where we will place all the Digital Teacher web application files. Alternatively, we may replace "pavilion" with "localhost."
We will discuss on how to setup and configure PWS in more details in Chapter 12: Installing Personal Web Server.
Next, we specify the physical and virtual locations of dtLoginNT.htm, the ASP login file. Its physical location information is used by the Digital Teacher authoring program to find the file. The virtual location information is used by our personal web server to load the file on our web browser.
Note that our login file is stored in the root folder. Since the login page is supposed to be the place from which we (our students) will access all of our Digital Teacher lesson files, the root folder can be the best location to be referenced (its path) in each lesson file. Unless you have a compelling reason for setting up Digital Teacher Web Application in another directory, we suggest that you follow the same setup as shown in the figure. Later on, when you're getting familiar with Digital Teacher Web Application, you can change the configuration to the way you prefer.
At this point, you might have noticed that the file extension of the login file (dtLoginNT.htm) for the .ASP type lesson is HTM. It is just a plain HTML web page. Then, why should we load this plain HTM file from our web server? Can't we simply double click the file to load it on our browser?
If viewing the login page were the only purpose, loading it from anywhere on our
disk would not matter. However, our purpose is to access a lesson page from inside the
login page.
So, if the login page had not been loaded from the web server, we would not be able to
access the lesson page - which is an ASP page. An ASP file can only be loaded from PWS.
For example, if we load the login page from a local path, as shown in the first address box, we cannot access the .ASP type lesson from the login page. To access the lesson page, we must be in the login page that has been loaded as a virtual web page running on our web server(PWS). The second address box shows the URL when the login page was loaded as a virtual web page.
Tip: To load dtLoginNT.htm from PWS, we might want to create a plain .HTM page that contains the link to dtLoginNT.htm. For example, we can create a starting page as follows
<HTML>
<HEAD>
<TITLE>To load Digital Teacher Login Page</TITLE>
</HEAD>
<BODY>
<A HREF="http://myComputerName/digitalteacher/dtLoginNT.htm">Digital Teacher Login Page</A>
or optionally
<A HREF="http://localhost/digitalteacher/dtLoginNT.htm">Digital Teacher Login Page</A>
</BODY>
</HTML>
and save it as StartPage.htm in the directory where dtLoginNT.htm is stored. In order to load dtLoginNT.htm from PWS, we can simply double click StartPage.htm to open it (as a local file) on the browser and then, click the link to load dtLoginNT.htm as a web page.
Note: If we are going to preview a lesson as soon as it is generated from Digital Teacher,
we don't need to worry. As mentioned earlier in this chapter, Digital Teacher will
automatically load our login page. If, however, we want to view the lesson outside from
Digital Teacher, say from Windows Explorer, we would need to open our browser first and
then type in the URL of the login page in the address box.
Copyright 2001-2002 Francis Software, Sunnyvale, California