Page 509
FIG. 19.1
Defining virtual
directories for the
Microsoft IIS Web
server.
After defining the virtual directories, the Web server will most likely have to be stopped and then started to get the Web listener to recognize the new configuration. This can usually be done through the Web server's browser administration interface or in the Windows NT control panel. Web servers are normally running as services under NT, so going to the Services applet under the NT Control panel and stopping the service and restarting the service will load the modified configuration.
CAUTION |
While stopping and restarting the Web server is a quick way to reinitialize a Web server after configuration changes, this is not necessarily a task for the novice. Some servers such as Microsoft's IIS should be stopped and started only via their administrative utilities. The safest way to reinitialize a Web server is to shut down the NT server and restart it. |
CAUTION |
When configuring virtual directories, make sure the syntax for the definition is correct for the Web server you are using. When I was configuring the virtual directories on the Oracle Web server, just leaving out a slash at the end of the virtual directory definition prevented the Web server from restarting until the entry was corrected. |
Page 510
To set up a Web cartridge forms implementation, the following steps need to be performed. Remember, that the cartridge implementation of Web forms requires that the Oracle Web Broker be installed. If this software is not installed on your Web server, it will need to be installed before the following steps can be performed:
Once the Oracle Web Request Broker is installed, an Oracle WebServer Administration Icon is placed in the Oracle for NT group. Selecting this icon will start your Web Browser, loading the Oracle WebServer configuration page (see Figure 19.2). This page connects to the Oracle WebServer configuration port. You will be prompted for the username and password that you entered during the products installation.
FIG. 19.2
The Oracle WebServer
configuration page.
Selecting the WebServer Manager link will take you to the WebServer Administration page shown in Figure 19.3 where you have several options. Two of these options, Oracle Web Listener and Web Request Broker, are used to configure the Web-related areas.
The Oracle Web Listener selection configures the Webserver, whether it is an Oracle, Microsoft, or Netscape server. Selecting this link will take you to a page that identifies the Web- server presently running and will allow you to modify the listener configuration (by calling up the corresponding server's Web-based configuration page). This is where virtual directories and other Web server configuration items are set.
Page 511
The Web Request Broker selection configures Cartridge configuration for Oracle's Web forms implementation. This is the section that will be used to perform most of the Cartridge configuration steps that follow.
Following is a list of all of the items that are available on the Oracle WebServer Manager page shown in Figure 19.3:
Throughout the configuration of the cartridge, while modifying the parameters, it was not uncommon to have connections failures to the Webserver. When these errors would occur, simply resubmitting the modification by selecting the Modify Cartridge Configuration button shown in Figure 19.4 again would correct the situation.
FIG. 19.3
Oracle WebServer
Administration Page.
Creating the Cartridge for Web FormsFrom the Web Request Broker Administration screen, select the MODIFY link. This will take you to the WRB Cartridge Administration screen. From here, go to the Cartridges section of the page and in the text entry box next to the Create Cartridge button, enter the name for your new cartridge. For our example, we will use Web_cart.
Select the Create Cartridge button and the WRB Cartridge Configuration page will be displayed. In the Cartridge parameters section, enter the desired Cartridge parameters. I found
Page 512
using the following parameters were sufficient to configure the cartridge and yet leave it generic enough to allow the one cartridge to be used for all Web forms. The parameters' names are case-sensitive, so remember how they are entered here in the cartridge because the same names will be used in the base HTML file (see Figure 19.4).
The first parameter entered is baseHTML. This is the absolute path and file name of the base HTML file that the cartridge will use when calling up the form.
Next, the HTMLdelimiter is input. This is the special character that acts as a delimiter for variables in the base HTML file defined earlier.
Next, the Code variable is defined. This is a case-sensitive variable that points to the Java code that executes the Oracle form within the Web browser. This variable MUST be entered as defined in Table 19.3.
Finally Codebase is defined. This is the virtual directory for the Oracle application code for the Java class files defined earlier.
FIG. 19.4
The Create Cartridge
Parameters Screen after
successful modification.
When using a Cartridge, I found it useful to keep the configuration nonspecific to an individual forms application. In other words, do not use the options that allow you to hard code userid information, or forms module information. Not hard-coding this information will allow you to use one cartridge for all your forms Web applications by modifying the URL that calls the application.
The following table details the values used in my examples for the values of these Cartridge parameters:
Page 513
Table 19.3 Web Cartridge Configuration
Parameter | Value |
baseHTML | D:\ORAPROD\WEB\HTML\WEB_CART.HTM |
HTMLdelimiter | ^ |
Code | oracle.forms.uiClient.v1_4.engine.Main |
Codebase | /Web_code/ |
Once you've finished entering these parameters, select the Modify Cartridge
Configuration button. When this modification is completed, a success message will appear at the top of
the page. After this, select the "Go back to WRB Configuration for this Listener" link to continue
on with the next step. Note, if your cartridge does not appear in the list of existing WRB
Cartridges, do not panic. A refresh of the Web page may be required to get the list to update.
Register the Web Form CartridgeNow that we have created the cartridge, the next step is to register the Cartridge we just created with the Web forms handler. This is done by scrolling down the WRB Cartridge Administration page to the Applications and Objects section as shown in Figure 19.5.
Enter the following values for your Cartridge as shown in Figure 19.5:
When completed, select the Modify WRB Configuration button to update the Broker configuration. Success is indicated at the top of the page once the configuration is completed and the page is reloaded by the Broker.
Create a Virtual Directory for the Web Form CartridgeThe next step is to create a virtual directory for the Web Cartridge. This is again performed on the WRB Cartridge Administration page by scrolling down to the Applications and Directories section of the page as shown in Figure 19.6.