Platform SDK: IIS SDK
      [IIS 5.0] [IIS 5.1] [IIS 6.0]

Response.AppendToLog

The AppendToLog method adds a string to the end of the Web server log entry for the request. You can use it multiple times in one section of script. Each time the method is used, it appends the specified string to the existing entry.

Syntax

Response.AppendToLog string

Parameters

string
The text to append to the log file. Because fields in the log are comma-delimited, this string cannot contain any commas (,).

Remarks

To record the specified string in the log file, you must enable the URIQuery option of the Extended Properties property sheet for the site whose activity you want to log. To access this property sheet, from IIS Manager, right-click the Web site, and select Properties. On the Web Site tab, verify that Enable Logging is selected, and then click Properties. Note the default settings on the Extended Properties property sheet.

Example

The following example adds the text "content updated" to the log file:

<% Response.AppendToLog "My custom log message" %>

Applies To

Response Object

Requirements

Platforms: Windows 2000 with IIS 5.0 installed, Windows XP with IIS 5.1 installed, Windows Server 2003 family with IIS 6.0 installed

Platform SDK Release: February 2003
What did you think of this topic?
Order a Platform SDK CD