Share via


Standard Execution Flow for Solution Sites

The flow of standard execution within the Solution Sites Page Execution Model for Solution Sites can be understood in terms to the files included on a Web site page. For more information about the different types of include files, see Include Files for Solution Sites.

Processing begins in the first include file, either include\header.asp or include\txheader.asp, in which a small amount of script is executed in order to add some standard response header entries.

The two types of files that are typically included next are the constants file and the utility routine files. Since these files do not contain any global code, that is, code outside of any function or subroutine, they can be included in any order relative to the other include files. The lack of global code in these files means that their inclusion does not necessarily result in any processing. If one or more routines in these files is called, it occurs at a later stage in the execution flow. For more information about when the code in these files enters the flow of execution, see Custom Execution Flow for Solution Sites.

The next include file, include\setupenv.asp, is central to the standard execution flow. This file is responsible for defining and (generally) initializing several dozen variables that can be used further on in the processing. It is also responsible for doing some correction of the URL (by calling the routine CorrectRequest). Finally, it ends by calling the routine Main, which is typically implemented as the first routine following the file inclusions. All custom processing for the page occurs within the Main routine and any routines called from within it.

After the routine Main returns, the HTML and the script in the final include file, either template\layout1.asp or template\no_menu.asp, is processed. All processing up to this point is entirely in script, as the opening HTML element has not yet been encountered. These layout files are mostly HTML, with the exception of a few include files that contain executable script, and the writing of the contents of a couple of page layout variables using the Internet Information Services (IIS) "<%=" directive.

For more information about the details of page layout, and the page layout variables, see Page Layout for Solution Sites and Page Layout Variables for Solution Sites, respectively.

See Also

Custom Execution Flow for Solution Sites

Copyright © 2005 Microsoft Corporation.
All rights reserved.