[ Previous ] [ Contents ] [ Index ] [ Next ]

Ns_Log

Overview

Log formatted message

Syntax

    void Ns_Log(
    	Ns_LogSeverity severity,
    	char          *fmt,
    	...
    );

Description

The Ns_Log function writes formatted messages to the server log file. Allowable values for severity are:
    Notice

Something interesting occurred.

    Warning

Maybe something bad occurred.

    Error

Something bad occurred.

    Fatal

Something extremely bad occurred. The server will shut down after logging this message.

    Bug

Something occurred that implies there is a bug in your code.

    Debug

If the server is in Debug mode, the message is printed. Debug mode is specified in the [ns/parameters] section of the configuration file. If the server is not in debug mode, the message is not printed.

Example

    char *hServer; /* virtual server handle */
    char *hModule; /* module handle */
    Ns_Log(Notice, "Initializing module %s on virtual server %s",
    					hModule, hServer);
    

Top of Page

[ Previous ] [ Contents ] [ Index ] [ Next ]
Copyright © 1996 America Online, Inc.