Without further ado (no pun intended), let's create a simple ASP script – the ASP 'code' that makes ASP really dynamic and differentiates it from static HTML. ASP scripts can be written in any scripting language, such as Visual Basic Scripting Edition (VBScript), JScript, or JavaScript. A script can be inserted anywhere in an HTML document, that is, anywhere between the
and <HTML>
tags (these demarcate the start and end points of the HTML page). You will find that ASP Scripts are an easy way to begin creating interactive pages. Using scripts and ASP, for example, you can collect information from an HTML form, and generate an HTML document personalized with a customer's name that can then be returned to their browser. Since this is a book about database programming, we will be using a database to display customized information to users over the Internet. I think you will find that ASP provides a compelling approach to accomplishing these tasks.</HTML>
Previously, to collect information from an HTML form, you would have had to learn a complicated programming language to build a Common Gateway Interface (CGI) application. Now you can collect and analyze data from a form by using simple instructions that you embed directly into your HTML/ASP documents. The good news is that you do not need to learn a full programming language or compile programs separately to create interactive pages.
We will be using VBScript because it is very simple and is really a subset of Visual Basic – this means you already know it. VBScript is a programming language that looks and feels like Visual Basic! You can send VBScript embedded in an HTML page to a client's browser to perform some tasks (the limitation of this particular technique is that VBScript is not supported at all on any browser other than Microsoft's Internet Explorer). We will use VBScript on the server side, so that the limitations of the client-level browsers don't matter - VBScript is the perfect choice for server-side script no matter what browsers your users have.