VBScript brings active scripting to the web client and web server environments in the Internet Exlporer and the Internet Information Server respectively. In general VBScript talks to host applications using ActiveX scripting. When coding VBScript one should attempt to keep as much as possible in the HEAD section of a document since it ensures that all code is read and decoded prior to any calls from with the BODY section. Code can be embedded within tags within the BODY section. Sometimes this is neccessary.
Note that there are generally accepted coding conventions for VBScript, published by Microsoft. Use of a consistent set of coding conventions allows for easy reading and understanding of code. This allows more than one person to maintain previously written code. These standards are of the form as shown below where the type of object or variable is used as a three character descriptive prefix for the name of the object or variable.