Introduction to Active Server Pages

Slides:



Advertisements
Similar presentations
Copyright © 2004 ProsoftTraining, All Rights Reserved. Lesson 11: Advanced Web Technologies.
Advertisements

Java Script Session1 INTRODUCTION.
Adding Dynamic Content to your Web Site
Hacking Web Servers April 15, 2010 MIS 4600 – MBA © Abdou Illia.
Languages for Dynamic Web Documents
DT211/3 Internet Application Development Active Server Pages & IIS Web server.
Building Applications using ASP.NET and C# / Session 1 / 1 of 21 Session 1.
Server-Side vs. Client-Side Scripting Languages
1 Chapter 12 Working With Access 2000 on the Internet.
ASP Tutorial. What is ASP? ASP (Active Server Pages) is a Microsoft technology that enables you to make dynamic and interactive web pages. –ASP usually.
1 Today: Introduction to ASP- Part 1 Explain the client/server architecture Explain Web-based client/server applications Understand the essentials of Active.
Session 6 Server-side programming - ASP. An ASP page is an HTML page interspersed with server-side code. The.ASP extension instead of.HTM denotes server-side.
Introduction to ASP.NET. 2 © UW Business School, University of Washington 2004 Outline Static vs. Dynamic Web Pages.NET Framework Installing ASP.NET First.
INTERNET DATABASE Chapter 9. u Basics of Internet, Web, HTTP, HTML, URLs. u Advantages and disadvantages of Web as a database platform. u Approaches for.
1 Software Testing and Quality Assurance Lecture 33 – SWE 205 Course Objective: Basics of Programming Languages & Software Construction Techniques.
INTERNET DATABASE. Internet and E-commerce Internet – a worldwide collection of interconnected computer network Internet – a worldwide collection of interconnected.
1 Active Server Pages Active Server Pages (ASPs) are Web pages ASP = server-side scripts + HTML The appearance of an Active Server Page depends on who.
Multiple Tiers in Action
Active Server Pages Chapter 1. Introduction Understand how browsers and servers interacted when the Web was young Understand what early Internet and intranet.
1 CS6320 – Why Servlets? L. Grewe 2 What is a Servlet? Servlets are Java programs that can be run dynamically from a Web Server Servlets are Java programs.
Overview of ASP.NET Prepared By : Lec : Zalak Thakrar Follow Me on
Chapter 11 ASP.NET JavaScript, Third Edition. 2 Objectives Learn about client/server architecture Study server-side scripting Create ASP.NET applications.
Oral Presentation CSCE 330 ASP Tamiko Simmons Sherita Gee Robert Rhoden.
2440: 141 Web Site Administration Web Server-Side Programming Professor: Enoch E. Damson.
McGraw-Hill/Irwin © 2004 by The McGraw-Hill Companies, Inc. All rights reserved. Beginning Active Server Pages Barry Sosinsky Valda Hilley Programming.
Server Side Scripting Norman White. Where do we do processing? Client side – Javascript (embed code in html) – Java applets (send java program to run.
INTRODUCTION TO WEB DATABASE PROGRAMMING
Server- Side technologies Client-side vs. Server-side scripts PHP basic ASP.NET basic ColdFusion.
1 CS 3870/CS 5870 Static and Dynamic Web Pages ASP.NET and IIS.
Lecture Note 3: ASP Syntax.  ASP Syntax  ASP Syntax ASP Code is Browser-Independent. You cannot view the ASP source code by selecting "View source"
Dynamic Web Sites Chris North cs3724: HCI. Presentations matt ketner, sam altman, mike gordon Vote: UI Hall of Fame/Shame?
1 CS 3870/CS 5870 Static and Dynamic Web Pages ASP.NET and IIS.
ASP.NET Dr. Ralph Westfall May, Web Development Problem HTML designed to display static pages only interactive when user clicks links  can’t provide.
Basics of Web Databases With the advent of Web database technology, Web pages are no longer static, but dynamic with connection to a back-end database.
11/16/2012ISC329 Isabelle Bichindaritz1 Web Database Application Development.
9 Chapter Nine Compiled Web Server Programs. 9 Chapter Objectives Learn about Common Gateway Interface (CGI) Create CGI programs that generate dynamic.
Java CGI Lecture notes by Theodoros Anagnostopoulos.
ASP Introduction Y.-H. Chen International College Ming-Chuan University Fall, 2004.
Putting it all together Dynamic Data Base Access Norman White Stern School of Business.
Lecture Note 1: Getting Started With ASP.  Introduction to ASP  Introduction to ASP An ASP file can contain text, HTML tags and scripts. Scripts in.
VBScript. Introduction Visual Basic scripting language is client side scripting language. It is developed by Microsoft VBScript is subset of VB language.
EIW - ASP Introduction1 Active Server Pages VBScript.
ASP (Active Server Pages) by Bülent & Resul. Presentation Outline Introduction What is an ASP file? How does ASP work? What can ASP do? Differences Between.
ASP.NET in Definition: 1.ASP.NET is a web application framework developed and marketed by Microsoft to allow programmers to build dynamic web sites,
ASP. What is ASP? ASP stands for Active Server Pages ASP is a Microsoft Technology ASP is a program that runs inside IIS IIS stands for Internet Information.
ASP. ASP is a powerful tool for making dynamic and interactive Web pages An ASP file can contain text, HTML tags and scripts. Scripts in an ASP file are.
 Web pages originally static  Page is delivered exactly as stored on server  Same information displayed for all users, from all contexts  Dynamic.
ASP-2-1 SERVER AND CLIENT SIDE SCRITPING Colorado Technical University IT420 Tim Peterson.
JavaScript 101 Introduction to Programming. Topics What is programming? The common elements found in most programming languages Introduction to JavaScript.
1111 Creating HTML Programatically Objectives You will be able to Invoke C# code on the server from an ASP.NET page. Write C# code to create HTML.
ASP Syntax Y.-H. Chen International College Ming-Chuan University Fall, 2004.
Web Page Designing With Dreamweaver MX\Session 1\1 of 9 Session 1 Introduction to PHP Hypertext Preprocessor - PHP.
Introduction to ASP.NET development. Background ASP released in 1996 ASP supported for a minimum 10 years from Windows 8 release ASP.Net 1.0 released.
ASP.NET WEB Applications. ASP.NET  Web application framework developed by Microsoft  Build dynamic data driven web applications and web services  Subset.
A S P. Outline  The introduction of ASP  Why we choose ASP  How ASP works  Basic syntax rule of ASP  ASP’S object model  Limitations of ASP  Summary.
ASP Mr. Baha & Dr.Husam Osta  What is ASP?  Internet Information Services  How Does ASP Differ from HTML?  What can ASP do for you?  ASP Basic.
PHP is a server scripting language, and a powerful tool for making dynamic and interactive Web pages. PHP is a widely-used, free, and efficient alternative.
ASP – Web Programming Class  Ravi Anand. ASP – Active Server Pages What is ASP? - Microsoft Technology - Can Run using IIS/PWS/Others - Helps us create.
1 Chapter 1 INTRODUCTION TO WEB. 2 Objectives In this chapter, you will: Become familiar with the architecture of the World Wide Web Learn about communication.
Section 6.3 Server-side Scripting
Web Concepts Lesson 2 ITBS2203 E-Commerce for IT.
Active Server Pages Computer Science 40S.
Introduction to ASP By “FlyingBono” 2009_01 By FlyingBono 2009_01
Section 17.1 Section 17.2 Add an audio file using HTML
Development of Internet Application 1501CT - Sara Almudauh
PHP / MySQL Introduction
Client side & Server side scripting
JavaScript.
Introduction to JavaScript
Web Application Development Using PHP
Presentation transcript:

Introduction to Active Server Pages Active Server Pages (ASP) ASP Architecture Basic ASP Scripting Techniques ASP Object Model Request Object Response Object

ASP Architecture

Microsoft’s solution for developing dynamic web pages ASP Architecture Microsoft’s solution for developing dynamic web pages Uses VBScript, a variant of Visual Basic A subset of VB Internet-enabled Object-oriented architecture Provides objects for various functions such as database access, file access, etc. Supported by Microsoft’s IIS and Personal Web Server

Executed by web browsers Can be VBScript, Javascript, etc. Scripting in ASP An ASP can consist of HTML code Server side script Client side script Executed by web browsers Can be VBScript, Javascript, etc. Executed by web servers May be VBScript or Javascript, etc.

Dynamically edit, change or add any content of a Web page What can ASP do for you Dynamically edit, change or add any content of a Web page Respond to user queries or data submitted from HTML forms Access any data or databases and return the results to a browser Customize a Web page to make it more useful for individual users The advantages of using ASP instead of CGI and Perl, are those of simplicity and speed Provides security since your ASP code can not be viewed from the browser Since ASP files are returned as plain HTML, they can be viewed in any browser Clever ASP programming can minimize the network traffic

<title>My First ASP Page</title> </head> A Simple ASP Example <html> <head> <title>My First ASP Page</title> </head> <body> <% Response.Write("Welcome to my first ASP generated web page.") %> <br /> <%= "Today is " & date() & " and the time is " & time() %> </body> </html>

Create a new web application in FrontPage Mapping your web folder (dt211-3studentusername) from “erin.student.comp.dit.ie” to your machine. Select start, Programs, MicroSoft FrontPage Select Open Site Type in: http://www.student.comp.dit.ie/dt211-3username Now you should be able add your ASP file now.

<title>Document title</title> A Client side example <html> <head> <title>Document title</title> <script language="vbscript"> sub vbs alert("This is VBScript") end sub </script> <script language="javascript"> function js() { alert("this is JavaScript") }

A Client side example, cont. </head> <body> Select button: <input type="button" Name="vbs" value="VBScript" onclick="vbs()" /> <input type="button" Name="js" value="Javascript" onclick="js()" /> </body> </html>

Control Flow statements are divided into 2 types. Conditional Loop Control Flow in ASP Control Flow statements are divided into 2 types. Conditional Loop Conditional statements are If…Then…Else Select…Case Looping statements are Do…Loop For…Next While…Wend

<title>ASP Loop</title> </head> <body> <% A Loop example <html> <head> <title>ASP Loop</title> </head> <body> <% Dim i for i = 1 to 6 response.write("<h" & i & ">This is header " & i & "</h" & i & ">") next %> </body> </html>

<head> <title>ASP Loop</title></head> A If example <html> <head> <title>ASP Loop</title></head> <body> <% Dim h h = hour(now()) response.write("<p>" & now()) response.write(" (Irish Time) </p>") If h < 12 then response.write("Good Morning!") else response.write("Good day!") end if %> </body> </html>

There are two types of procedures, “Sub” and “Function”. Procedures are subroutines that can be called by the main program. It contains a different script level this separating local variables from global variables. There are two types of procedures, “Sub” and “Function”. “Sub” normally doesn’t return a value while “Function” returns a value

<html><head> <title>ASP Loop</title> A procedures example <html><head> <title>ASP Loop</title> <% sub vbproc(num1,num2) response.write(num1*num2) end sub %> </head><body><p> The result of the calculation is: <%call vbproc(3,4)%> </p><p> Or, you can call a procedure like this: </p><p> The result of the calculation is: <%vbproc 3,4%> </p> </body> </html>