Khurram's World - Server Object [ASP]
..Islam and Religion
 .Computer & IT
  Web Designing TIPS
..HTML & DHTML
..Active Server Pages
..JAVA & JAVA Applets
..JAVA & VB Script
..CGI & Perl
..Electronic Commerce
..Web Sites & Emails
 
Pakistan News Service
BayCareer Banner

ASP Built in Objects and Components

Response Request Server
Session Application Components
     

Server Object

The Server Object is used to access properties and methods on the server.
The ASP Server object gives you high level access to the server itself. Using its properties and mthoeds, you can create objects, execute code in other ASP files, translate virtual paths to physical paths, and perform server-side redirects. Here's where ASP begins to become truly interesting and powerful.
Syntax
Request.property
Request.method

Server Object Property

Property Description
ScriptTimeout Specifies the duration, in minutes, after which a script timeout if processing is not complete. The default values is 90 seconds, which I consider at least double the optimum value except for very busy sites or extremely large pages.

Server Object Method

Method Description
CreateObject(ProgID) Creates an ActiveX object. You provide a valid ProgID, for example Server.Createobject("Scripting.Dictionary").
Execute(filename) Executes another ASP script. ASP preserves the values of all intrinsic objects during the call. The executed pages may return a value, for example: ret=Server.Execute("aPage.asp").
GetLastError Retrieves the last ASP error values. Use this method when creating custom error pages.
HTMLEncode(string) Encodes the string argument by replacing ampersands, angle brackets, and other non-text characters with special tokens that the browser will display as the original character.
MapPath(path) Performs virtual path to physical path conversion. The primary use for the MapPath method is to obtain a full physical path to file resources, as required by the FileSystemObject.
Transfer(filename) Transfers processing to another ASP file. ASP preserves the values of all intrinsic objects. Unlike the Server.Execute method, this method does not return to the caller. Use this perform server-side redirects and save the round trip to the browser required by Response.Redirect.
URLEncode(string) Applies Base-64 encoding to the characters in the string arguments.