Installing The Example - Netscape ENTERPRISE SERVER 6.1 - NSAPI PROGRAMMER GUIDE Manual

Nsapi
Table of Contents

Advertisement

NameTrans Example
The
explicit_pathinfo
information for use by a CGI program. The extra path information is delimited
from the main URL by a specified separator, such as a comma.
For example:
http://
In this case, the URL of the requested resource (which would be a CGI program) is
http://
CGI program is
When choosing a separator, be sure to pick a character that will never be used as
part of the real URL.
The
explicit_pathinfo
the comma and puts it in the
object (
PATH_INFO
One side effect of
variable has the separator character tacked on the end.
Normally
that the server does not process any more
case we want name translation to continue after we have extracted the path info,
since we have not yet translated the URL to a physical pathname.

Installing the Example

To install the function on the Enterprise Server, add the following
magnus.conf
Init fn=load-modules shlib=
Inside the default object in
NameTrans fn=explicit-pathinfo separator=","
This
default object.
220
Netscape Enterprise Server NSAPI Programmer's Guide • April 2002 (Draft)
server-name
/cgi/marketing,/jan/releases/hardware
server-name
/cgi/marketing
/jan/releases/hardware
). CGI programs can access this information through the
rq->vars
environment variable.
explicit_pathinfo
directives return
NameTrans
to load the compiled function:
directive should appear before other
NameTrans
example allows URLs to explicitly include extra path
and the extra path information to give to the
.
function reads the URL, strips out everything following
field of the
path-info
is that the
REQ_PROCEED
NameTrans
yourlibrary
funcs=explicit-pathinfo
add the following
obj.conf
field in the
vars
request
CGI environment
SCRIPT_NAME
when they change the path so
directives. However, in this
Init
directive:
NameTrans
directives in the
NameTrans
directive to

Advertisement

Table of Contents
loading

This manual is also suitable for:

Enterprise server 6.1

Table of Contents