Oracle iPlanet Web Server 7.0.9 Administrator's Configuration File Reference

document-root

The document-root function specifies the root document directory for the server. If the physical path is not set by a previous NameTrans function, the http://server-name/ part of the path is replaced by the physical path name for the document root.

When the server receives a request for http://server-name/somepath/somefile, the document-root function replaces http://server-name/ with the value of its root parameter. For example, if the document root directory is /opt/oracle/webserver7/https-server/docs, when the server receives a request for http://server-name/a/b/file.html, the document-root function translates the path name for the requested resource to /opt/oracle/webserver7/https-server/docs/a/b/file.html.

You can also specify a document root in the virtual-server element of server.xml. For more information, see virtual-server.

This function always returns REQ_PROCEED.

NameTrans directives listed after this directive will never be called. Ensure that the directive that invokes document-root is the last NameTrans directive.

There can be only one root document directory. To specify additional document directories, use the pfx2dir function.

Parameters

The following table describes parameters for the document-root function.

Table 7–6 document-root Parameters

Parameter 

Description 

root

File system path to the server’s root document directory. 

bucket

(Optional) Common to all obj.conf functions. Adds a bucket to monitor performance. For more information, see The bucket Parameter.

Example

NameTrans fn="document-root" root="/opt/oracle/webserver7/https-server/docs"

NameTrans fn="document-root" root="$docroot"

See Also

pfx2dir