![]()
|
|
||||||||||||||||||
|
|
PresentationAs we saw it in the introduction, ASP 3.0 uses different objects to describe the interactions between the client and the Web server. Their are 7 of them:
An ASP object may be made 3 elements: properties, methods and collections. A collection
is an associative array (an array that may be indexed by anything, like strings). For instance, ASP builds a dedicated
collection in the Request object (Server.Form) to store the content of a form. We use these 3 elements as
we ordinary use the properties and methods of an object in the language we chose to write the ASP code (mostly
These various objects are used in different scopes. We can represent these scopes on the following sketch: ![]() The Request objectThe Request objects represents the query a Web browser sends to the Web server to retrieve the ASP page. This object contains in different collections the HTTP message the client has sent to the server. For instance, this object holds a special collection to store the content of a form we have sent to the server. This object has only one property and one method. This object is mostly made of collections:
The Response objectThe Response object represents the HTTP response to to request of the client.
It is the header of the response (the HTTP status for example) as well as the body of the response (the HTML page).
We use this object to write the dynamic content from the ASP code, in particular thanks to the This object has more methods and properties than the object Request, but it has only one collection:
The ObjectContext objectThe ObjectContext object is used to control the ASP transactions that are ordinary managed the Microsoft transaction server (MTS). It is necessary to use the ASP directive The object
The Application objectThe Application object represents the Web application. It is a container that holds the dynamic data available to all visitors (the number of currently connected visitors). To simplify, the Application object holds the global variables of the application. The Session objectThe Session object is used to manage the ASP sessions. A session is an environment peculiar to each visitor; it is mostly used to store visitor-specific data (for instance, the list of articles he is buying on a merchant Web site). These data are available for a given length of time. The Server objectThe Server represents the Web server and the ASP engine. We use this object to manage some parameters of the Web server and instanciate user objects. The ASPError objectThe ASPError object collects information about the errors that occurs while processing the ASP code of the page. |
||||||||||||||||||
|
Copyright © 2000-2002 themanualpage.org - This site is submissive to the terms of the GNU GPL and FDL licences. |
|||||||||||||||||||