As we learned in the previous chapter, an ASP page is a mix of text, HTML tags and server-side script blocks. The server script blocks in ASP are always surrounded by the <% and %> delimiters, which tell the ASP ISAPI filter which part of the ASP page has to be executed. Server scripts are executed on the server, and the result sent to the browser is just plain HTML & text.
Here is an example of a very simple ASP page:
My first ASP page was executed on <%= Now() %>.
The only server-side script above contains the Now() VBScript function, which returns the current date and time. When IIS executes this ASP page, it replaces <% = Now() %> with the current date and time and you will see the following in your browser:
My first ASP page was executed on 11/09/2004 1:13:12 PM