Open In App

ASP Introduction and Installation

ASP stands for Active Server Page. It is commonly known as Classic ASP or ASP Classic. ASP is a server-side scripting language that is used for executing the scripts on the webserver. This technology was developed by Microsoft. It is an old but still useful tool used to create dynamic webpages. 

ASP is a program that runs inside a web server. Active Server Pages is a programming environment that gives you the ability to generate interactive dynamic HTML pages with the help of client-side and server-side scripting. 



What does the ASP file contain:

An ASP file has an extension “.asp”. It is the same as HTML Files. An ASP file can contain server scripts in addition to HTML Tags. In an ASP page, VB Script is usually used as a server-side and JavaScript as the client scripting language. 



Uses of ASP:

How does it work?

How to run ASP File?

  1. Firstly download and install a setup on your computer.
    • Press the Windows + R key and type appwiz.cpl in the Run box and press enter.

    • Select “Turn Windows features on or off”

    • Now click on the Internet Information Services check box and select sub-components are given below. It will take some time after click OK.

    • Go to your browser and navigate to localhost.

  2. After Installation, Search for a new folder named “Inetpub” on the hard drive of your PC.
  3. Inside the “Inetpub” Folder, Open a new folder called”wwwroot.”.
    C:\inetpub\wwwroot
  4. Create a new folder named “Geeks” inside wwwroot. 
  5.  Create a new file named “GFG.asp” inside Geeks Folder.
  6.  Write some ASP code and save the file as “GFG.asp”.
  7.  Now, check that your web server is running properly or not.
  8. In the end, Open your browser and type “http://localhost/Geeks/GFG.asp”, to view your first web page

Example: A Simple Hello world Program in ASP.




<!DOCTYPE html>
<html>
<body>
  
<%
response.write("Hello World")
%>
  
</body>
</html>

Output:

Hello World 

Explanation: This is a very basic example of a Classic ASP page that returns the phrase “Hello World” to the browser along with the rest of the standard HTML. The HTML portions are static, i.e. the server will send them to the browser as-is. The parts delimited by <% %> are what the server will actually process before sending it to the client.


Article Tags :