ASP » Objects » Server

Version: Modified in version 3.0

The Server object provides access to the utility functions of the server.

Properties

ScriptTimeout

The ScriptTimeout property is the amount of runtime in seconds for a script before it terminates.

Methods

CreateObject

Syntax: Server.CreateObject(ObjectID)

The CreateObject method creates an instance of an object to use in an Active Server Page.

Execute

Syntax: Server.Execute(Path)


The Execute method allows you to call another ASP page from inside an ASP page. When the called ASP page completes its tasks, you are then returned to the calling ASP page.

GetLastError

Syntax: Server.GetLastError( )

The GetLastError method returns an ASPError object that describes any pre-processing, runtime, or script compiling errors that occurred.

HTMLEncode

Syntax: Server. HTMLEncode (String)

The HTMLEncode method applies HTML syntax to a specified string of ASCII characters.

MapPath

Syntax: Server.MapPath(Path)

The MapPath method maps a relative or virtual path to a physical path.

Transfer

Syntax: Server.Transfer (Path)


The Transfer method allows you to transfer all of the state information for all of the built-in objects from one ASP page to another. Unlike the Execute method, when the ASP page that you have transferred to is finished, you do not return the original ASP page.

URLEncode

Syntax: Server.URLEncode(String)

The URLEncode method applies URL rules to a specified string of ASCII characters.