Introduction
$Imagemap
Invokes the built-in image mapping server.
$Form
Invokes the built-in form processing facilities.
$Wizard
Creates new HTML documents using Wizards, templates and styles.
The PowerWeb Commands act like a normal URL, but are mapped to internal built-in commands within the PowerWeb Server, bypassing the overheads and complications of CGI programming.
This performance advantage is particularly significant for imagemap processing, where the overhead on other vendor's servers of loading the imagemap program is typically 80% of the workload. PowerWeb's low overhead ensures that adding clickable images to your pages doesn't bring your server to its knees.
The /$ImageMap command is fully compatible with existing image map processing programs, and the format of its configuration files is also fully compatible with servers such as NCSA, making it a true drop-in replacement.
When PowerWeb configures itself automatically on installation, it defines an Alias which maps your existing /cgi-bin/imagemap programs to the built-in /$imagemap. You don't need to do anything to your existing documents to take advantage of PowerWeb's built-in imagemap support.
Process forms automatically with PowerWeb's parameter-driven forms handling. In conjunction with PowerWeb Macros, you can manipulate and process multi-page forms without resorting to CGI scripts.Parameters:To invoke the automatic form processor, use /$Form as the action for your form tag in your HTML document.
For example:
<Form Action="/$Form" Method=POST>The /$Form command requires some parameter fields to be contained within your form so that these are submitted along with the rest of the form data. These parameters are coded as hidden fields within your document.
For example:
<Input type=hidden name=form_fields value="config:/Version,*">
Example:form_file
Specifies the file in which to save the form data.
form_url
Specifies the URL (local or external) to which the form data should be forwarded.
form_fields
Specifies the list of fields to store or to forward. Each field name should be separated by a comma. The special field name '*' outputs all fields. By default, if no form_fields parameter is given, all fields are output.
form_format
The format for storing the fields is by default Comma-Separated-Variable (CSV). The alternative format is "arglist", which uses the HTTP method of encoding fields and their values.
form_check
Defines a local virtual URL of a PowerWeb Macro document that performs field validation. The PowerWeb Macro document is expected to set the variable "form_valid" to 1 or 0 accordingly. If the form contents are invalid, the PowerWeb Macro can output its own error messages to be sent to the client, in which case the form data is not stored on the server.
form_ok
Defines a message to display to the client upon acceptance of valid form data.
form_before
Specifies an API hook to call to perform pre-processing of the form data. Internal attributes within the parameter value define which function to call.The Attributes Are:
Example:Exec
This must be "api", or "rexx".
Module
If the "exec" is "api", this is the name of the dynamic library which contains the API Hook Function to call. If the library is in the PowerWeb Server bin directory, you do not need to specify a path or an extension. For a "rexx" interface, this attribute is the name of the command file.
Function
The name of the function to call within the specified module. The function must comply with the PowerWeb API Hook interface specification.<Input type=hidden name=form_before value="exec=api module=forms function=before">
form_after
Specifies an API hook to call to perform post-processing of the form data after it has been stored. Internal attributes within the parameter value define which function to call, just like for the "form_before" parameter.
<Form Action="/$form" Method=POST><Input type=hidden name=form_file value=/example/rexxform.frm>
<Input type=hidden name=form_fields value="connect:/RemoteAddress,*">
<Input type=hidden name=form_before value="exec=rexx module=/example/rexxform.cmd">Your name: <Input type=text name=name>
<Input type=submit value="Submit">
</Form>
This would call the Rexx module /example/rexxform.cmd to perform any pre-processing required before storing the data set in the file /example/rexxform.frm, which would have as its first field the IP address of the remote client who submitted the form.
The /$Wizard command is used in conjunction with PowerWeb Macros to automatically generate new HTML documents based on templates.Parameters:The user executing the /$Wizard command must have permission to execute protocol "HTTP" with the "PUT" method for the resource specified in the "virtual_destination".
template
Specifies the local URL which contains the template document.
destination
Specifies the local URL in which the generated document should be stored.