0% found this document useful (0 votes)
18 views

Output

The document discusses Active Server Pages (ASP) which allows code to be executed on a server. It contains 3 key points: 1) ASP files use a ".asp" extension and can contain HTML, text, scripts and other code. Scripts in ASP files are executed on the server. 2) The Response object in ASP is used to send output to the user from the server and has collections, properties and methods to do so. 3) ASP files can use Visual Basic Script (VBScript) to add dynamic functionality like conditionals, procedures and loops like a "For" loop shown in an example.

Uploaded by

Manoj Kachariya
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
18 views

Output

The document discusses Active Server Pages (ASP) which allows code to be executed on a server. It contains 3 key points: 1) ASP files use a ".asp" extension and can contain HTML, text, scripts and other code. Scripts in ASP files are executed on the server. 2) The Response object in ASP is used to send output to the user from the server and has collections, properties and methods to do so. 3) ASP files can use Visual Basic Script (VBScript) to add dynamic functionality like conditionals, procedures and loops like a "For" loop shown in an example.

Uploaded by

Manoj Kachariya
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 10

Output

<html>
<body>
<%
response.write("Hello World!")
%>
</body>
</html>
What is ASP?
• ASP stands for Active Server Pages
• ASP is a Microsoft Technology
• ASP is a program that runs inside IIS
• An ASP file is just the same as an HTML
file
• An ASP file can contain text, HTML, XML,
and scripts
• Scripts in an ASP file are executed on the
server
• An ASP file has the file extension ".asp"
Response Object
The ASP Response object is
used to send output to the user
from the server. Its collections,
properties, and methods are
described below:
Request Object
When a browser asks for a page from a
server, it is called a request.
<html>
<body>
<%
="Hello World!"
%>
</body>
</html>
VB Script Example
<html>
<body>
<script type="text/vbscript">
Function greeting()
If i < 10 Then
  document.write("Good morning!")
Else
  document.write("Have a nice day!")
End If
End Function
</script>
</head>
<body onload="greeting()">
</body>
</html>
Procedures

<html>
<head>
<%
sub vbproc(num1,num2)
response.write(num1*num2)
end sub
%>
</head>
<body>
<p>Result: <%call vbproc(3,4)%></p>
</body>
</html>
For Loop
<html>
<body>
<script type="text/vbscript">
For i = 0 To 5
  document.write("The number is " & i & "<br />")
Next
</script>
</body>
</html>

You might also like