Calling a Servlet From an HTML Form

Topics:

How to:

You can call a servlet by either:

Syntax: How to Call a Servlet From an HTML Form

Specifying an Absolute Address:

<FORM ACTION="http://hostname/context_root/servlet/servlet_name"

where:

context_root

Is the configurable context root for the ReportCaster web application in your Application Server configuration. By default, this is /ibi_apps.

hostname

Is the host name of the web server.

servlet_name

Is the name of the servlet.

Specifying a Relative Address:

<FORM ACTION="/context_root/servlet/servlet_name"

where:

context_root

Is the configurable context root for the ReportCaster web application in your Application Server configuration. By default, this is /ibi_apps.

servlet_name

Is the name of the servlet.

Servlet Parameters

Reference:

The HTML calling forms prompt you for parameter values to generate the query string passed to a servlet.

  • If you do not supply a required value but a default exists, the servlet uses the default.
  • If you do not supply a required value and no default exists, the servlet returns a message. For example, the following message is generated when you attempt to run the DSTRUNNOW servlet without specifying a job description or schedule ID:
    Either IBIB_jobdesc or IBIB_scheduleid must be specified.

Reference: ReportCaster Servlet API Schedule Identification Parameters

The ReportCaster Servlet API provides two properties to identify a schedule:

  • IBIB_jobdesc. This is a user-supplied description that identifies a report request (job) scheduled for execution and distribution. The value must be unique for a given Execution ID. The description can be up to 90 alphanumeric characters with embedded blanks and special characters.
  • IBIB_scheduleid. This is a unique, API-generated ID that identifies a scheduled job in the WebFOCUS repository. It is automatically created when a user schedules a job.

You can identify a job to the ReportCaster API with either the IBIB_jobdesc or the IBIB_scheduleid parameter.

WebFOCUS

Feedback