Members

Technology Zones

IBM Learning Center

Articles

Hosted By

MaximumASP

Info

Rated
Read 205,287 times

Contents

Related Categories

Beginning Active Server Pages - Introduction

Introduction

Active Server Pages enables a web developer to replace static HTML pages with 'live data'. This information might be from a database, or simply by using cookie information. But why does this have any relevance to a VB website? The reason is Active Server Pages use Visual Basic as its main language (it also supports Javascript), and therefore makes it easy for a VB developer to become an ASP developer too. However, please note that this tutorial assumes some knowledge of HTML.

Changes in VB Web Tutorials

VB Web have introduced a few changes in its tutorials. The first are these boxes, which provide information related to the topic being discussed, but not essential to the tutorial! Next, is the highlighting of code. Any new code has a light grey background. Code that you have come across before, and hasn't changed has the standard white background.

First, lets take a look behind the idea of Active Server Pages. Normally, when someone visits a site, his browser sends a request for a certain file, such as index.htm. The server will then return this file to the client PC, and it will be displayed in the browser:

Active Server Pages, meanwhile, allow Visual Basic script to be processed on the server before sending the file back to the client.

This has a number of benefits

  • Unlike client-side code, such as the javascript that makes ad windows popup, the browser does not need to understand VB - it doesn't even get to see it.
  • The VB code can act on information passed to the page, such as from an internet form or a querystring (this is data passed in the URL after the ? ... take a look at this pages URL!). It can then use this information to display data, or retrieve specific information from a database
  • Only the smallest amount of data is sent to the client - only the HTML that the page outputs is sent, not the VB code. This also means that the authors VB programming work is protected from visitors!

James first started writing tutorials on Visual Basic in 1999 whilst starting this website (then known as VB Web). Since then, the site has grown rapidly, and James has written numerous tutorials, articles and reviews on VB, PHP, ASP and C#. In October 2003, James formed the company Developer Fusion Ltd, which owns this website, and also offers various development services. In his spare time, he's a 3rd year undergraduate studying Computer Science in the UK. He's also a Visual Basic MVP.

Comments

  • Re: [1010] Beginning Active Server Pages - absolute beginner!

    Posted by michael poxon on 16 Dec 2006

        Hi,
    When I say I'm an ASP beginner, I mean it! I've only written one trivial bit of code, and got a blank page. I see now that's described in the article snippet below. I did ind...

  • .I want to know how to save the files.whats the extensions...

    Posted by writetoksk on 04 Oct 2006

    hi,


    its first i started ASP.I want to know how to save the files.whats the extensions...Where can i get the sample programs

  • Posted by James Crowley on 28 Dec 2004

    Are you running IIS ? And are you viewing it in your browser via the correct URL? (ie something starting with http:// rather than file:// ) ?

  • Posted by James Crowley on 28 Dec 2004

    It does - you just can't see it ;) We've got an ISAPI filter that rewritse /show/1010/ to something like /show.aspx?id=1010

  • It's not working ;_;

    Posted by HyperHacker on 12 Dec 2004

    Is there something special I have to do besides saving it as a .asp file, or does it just not work on my server? It just spits out the code, even HTML, as plain text.

    [code]
    Let's see if ASP...