Web Server Gateways


Usage requirements

The following sections describe use requirements for Web server gateways.

Reading the index.html file

Use your Web browser to view the index.html file in your jConnect installation directory. index.html provides links to the jConnect documentation and sample code.

Note   If you use Netscape on the same machine where you have installed jConnect, be sure that your browser does not have access to your CLASSPATH environment variable. See "Restrictions on Setting CLASSPATH When You Use Netscape" in Chapter 3 of the Sybase jConnect for JDBC Installation Guide and Release Bulletin.

Steps To view the index.html file

  1. Open your Web browser.
  2. Enter the URL that matches your setup. For example, if your browser and the Web server are running on the same host, enter:
    http://localhost:8000/index.html


    If the browser and the Web server are running on different hosts, enter:
    http://host:port/index.html


    where host is the name of the host on which the Web server is running, and port is the listening port.

Running the sample Isql applet

After loading the index.html file in your browser:

Steps To run the sample applet

  1. Click "Run Sample JDBC Applets."

    This takes you to the jConnect Sample Programs page.
  2. Move down the Sample Programs page to find the table under "Executable Samples."
  3. Locate "Isql.java" in the table and click Run at the end of the row.

The sample Isql.java applet prompts for a simple query on a sample database and displays the results. The applet displays a default Adaptive Server host name, port number, user name (guest), password (sybase), database, and query. Using the default values, the applet connects to the Sybase demonstration database. It returns results after you click Go.

Troubleshooting

On UNIX, if the applet does not appear as expected, you can modify the applet screen dimensions:

Steps To modify the applet screen dimensions

  1. Use a text editor to edit the following:

    $JDBC_HOME/sample2/gateway.html
  2. Change the height parameter in line 7 to 650. You can experiment with different height settings.
  3. Reload the Web page on your browser.

 


Copyright (C) 2005. Sybase Inc. All rights reserved.