1 Today: Introduction to ASP- Part 1 Explain the client/server architecture Explain Web-based client/server applications Understand the essentials of Active.

Slides:



Advertisements
Similar presentations
Java Script Session1 INTRODUCTION.
Advertisements

Introduction to PHP MIS 3501, Fall 2014 Jeremy Shafer
Languages for Dynamic Web Documents
IIS Technologies.
Server-Side vs. Client-Side Scripting Languages
1 Chapter 12 Working With Access 2000 on the Internet.
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 Web Database Processing
CVEV 118/698 Active Server Pages Lecture 3 Prof. Mounir Mabsout Elsa Sulukdjian Walid El Asmar.
1 ASP-Code Examples if....then....else end if for next do while loop database response.write “ “
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.
Introduction to Active Server Pages
How Clients and Servers Work Together. Objectives Learn about the interaction of clients and servers Explore the features and functions of Web servers.
Chapter 11 ASP.NET JavaScript, Third Edition. 2 Objectives Learn about client/server architecture Study server-side scripting Create ASP.NET applications.
Active Server Pages Points of Interest Chapters 1-4.
Oral Presentation CSCE 330 ASP Tamiko Simmons Sherita Gee Robert Rhoden.
1 Chapter 20 — Creating Web Projects Microsoft Visual Basic.NET, Introduction to Programming.
2012 •••••••••••••••••••••••••••••••••• Summer WorkShop Mostafa Badr
McGraw-Hill/Irwin © 2004 by The McGraw-Hill Companies, Inc. All rights reserved. Beginning Active Server Pages Barry Sosinsky Valda Hilley Programming.
INTRODUCTION TO WEB DATABASE PROGRAMMING
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
MSSQL & ASP. Client-Server Relationship Client-Server Relationship HTML Basics HTML Basics Scripting Basics Scripting Basics Examples Examples.
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.
CSCI 6962: Server-side Design and Programming Course Introduction and Overview.
LAYING OUT THE FOUNDATIONS. OUTLINE Analyze the project from a technical point of view Analyze and choose the architecture for your application Decide.
Copyright © cs-tutorial.com. Introduction to Web Development In 1990 and 1991,Tim Berners-Lee created the World Wide Web at the European Laboratory for.
1 CS 3870/CS 5870 Static and Dynamic Web Pages ASP.NET and IIS.
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.
3/8/00asp00 1 Active Server Pages from Microsoft Nancy McCracken Northeast Parallel Architectures Center at Syracuse.
IDK0040 Võrgurakendused I harjutus 06: PHP: Introduction Deniss Kumlander.
Server Side Programming ASP1 Server Side Programming Database Integration (cont.) Internet Systems Design.
HOW WEB SERVER WORKS? By- PUSHPENDU MONDAL RAJAT CHAUHAN RAHUL YADAV RANJIT MEENA RAHUL TYAGI.
Client Scripting1 Internet Systems Design. Client Scripting2 n “A scripting language is a programming language that is used to manipulate, customize,
Web Design and Development for E-Business By Jensen J. Zhao Copyright 2003 Prentice Hall, Inc. Web Design and Development for E-Business Jensen J. Zhao.
ASP Introduction Y.-H. Chen International College Ming-Chuan University Fall, 2004.
Tutorial 10 Programming with JavaScript
Creating Dynamic Web Pages Using PHP and MySQL CS 320.
Active Server Pages  In this chapter, you will learn:  How browsers and servers interacted on the Internet when the Internet first became popular 
IS 4506 Interactive Clients & Servers.  Overview Fat Client versus Fat Server Spectrum of Web content formats Active Server Pages Active Server Page.
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.
EIW - ASP Introduction1 Active Server Pages VBScript.
1 MSCS 237 Overview of web technologies (A specific type of distributed systems)
Active Server Pages Server-Side Scripting and Client-Side Scripting.
Overview of Form and Javascript fundamentals. Brief matching exercise 1. This is the software that allows a user to access and view HTML documents 2.
JavaScript Scripting language What is Scripting ? A scripting language, script language, or extension language is a programming language.
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. 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.
Client-side & Server-side Scripting ©Richard L. Goldman August 5, 2003 Requires PowerPoint 2002 or later for full functionality.
The Module Road Map Assignment 1 Road Map We will look at… Internet / World Wide Web Aspects of their operation The role of clients and servers ASPX.
IS-907 Java EE World Wide Web - Overview. World Wide Web - History Tim Berners-Lee, CERN, 1990 Enable researchers to share information: Remote Access.
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
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.
STRUCTURE OF JSP PRESENTED BY: SIDDHARTHA SINGH ( ) SOMYA SHRIVASTAV ( ) SONAM JINDAL ( )
ASP-2-1 SERVER AND CLIENT SIDE SCRITPING Colorado Technical University IT420 Tim Peterson.
1 CSC160 Chapter 1: Introduction to JavaScript Chapter 2: Placing JavaScript in an HTML File.
Web Page Designing With Dreamweaver MX\Session 1\1 of 9 Session 1 Introduction to PHP Hypertext Preprocessor - PHP.
PHP Tutorial. What is PHP PHP is a server scripting language, and a powerful tool for making dynamic and interactive Web pages.
Active Server Pages v.s. Java Server Pages Presenters: Lan Guo Qunying Fan Pei-Xun Wu Date:
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.
ASP – Web Programming Class  Ravi Anand. ASP – Active Server Pages What is ASP? - Microsoft Technology - Can Run using IIS/PWS/Others - Helps us create.
INT213 – WEEK 1 ASP tags and comments Variables, Constants, and "Literals" Simple Output.
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.
PHP using MySQL Database for Web Development (part II)
Active Server Pages Computer Science 40S.
Introduction to ASP By “FlyingBono” 2009_01 By FlyingBono 2009_01
PHP / MySQL Introduction
Client side & Server side scripting
An Introduction to JavaScript
Presentation transcript:

1 Today: Introduction to ASP- Part 1 Explain the client/server architecture Explain Web-based client/server applications Understand the essentials of Active Server Pages Write and edit simple ASP files.

2 Client/Server Architectures What is Client/Server Architecture? Client/Server Architecture is the structural design of a computer network. Components; - Clients, or client computers and their software - Servers, which include hardware and software

3 Client/Server Architectures A typical Client/Server Relationship - Users at the client computers send service requests to a server computer - The server computer process the requests sends the results back to the client computers.

4 Web-Based Client/Server Applications Flowchart of a Sample Web-based, three-tiered Client/Server architecture Internet Explorer - Netscape Transaction server Application Servers Data Server Web Server IIS - Apachi Access-SQL Server- Oracle Database Internet Web Browser

5 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 or what is viewing it. If the Web browser that receives it, an Active Server Page looks just like a normal HTML page. However, the file located in the server looks very different. In addition to text and HTML tags, you also see server-side scripts. This is what the Active Server Page looks like to the Web server before it is processed and sent in response to a request.

6 How ASP Works? 1.User brings up a Web site where the default page has the extension.asp. 2.The browser requests the ASP file from the Web server 3.The server-side scripts begins to run with ASP. 4.ASP processes the requested file sequentially (top-down), executes any script command contained in the file, and produces an HTML Web page. 5.The Web page is sent to the browser.

7 ASP vs HTML ASP = HTML + some other stuff! What is the difference? Basically we are taking the HTML and adding some elements... ASP files end with the.asp extension, so the Web server knows what it is. ASP files include server-side code that contain instructions for the server. Browser can not display your code! ASP files provide dynamic information

8 Active Server Pages Server-side scripts ~ HTML tags. ~ You can insert server-side scripts anywhere in your Web page-- even inside HTML tags. The server looks inside the ASP tags and runs the instructions, sends the results

9 Variables Every application uses variables, and ASP scripts are no exception! But there is no obligation in Visual Basic and VbScript No need to define the variables and variable types at the beginning of the program. But if you want you can... If you add the following line after the language info to the page; You must declare your variables.  i.e. dim number1 dim number2

10 Variables Basic Variable Types: numeric, alpha-numeric, and logical. No need to know other variable types, because when you assign a value to a variable, Visual Basic understands your variable type! variable_1 = 15 variable_2 = “15” variable_3 = true If you want to learn type of any variable; <% variable_1 = 15 Response.write vartype(variable_1) ‘it writes 2 to the page %> List of Variant type variables of the VBScript vbNull 1 contains no data, vbInteger 2 integer type, vbLong

11 VBScript Looping – flow controls Looping constructs provide the foundation for any application that must repetitively perform a task. Such as adding 1 to a variable, reading a text file, or processing an message. VBScript and Jscript provide several looping mechanism. For... Next, For each... in...Next, Do.. Loop While, Do...While...Loop, Do..Until...Loop, Do...Loop Until..., While...Wend conditional operators Conditional operators, together with variables and looping constructs, for the fundamental building blocks of applications. Such as sending a page to the client browser that consists of the current time and date and a greeting If..Then, If...then...else, If...then...Elseif...then else, Select...Case, Switch..case

12 How to Create ASP Pages? 1.Open notpad 2.Create the necessary HTML codes. 3.Add ASP codes into their respective places. 4.Save your file with the extension.asp. 1.Design the followings in FrontPage:

13 How to Create ASP Pages ? 2.Switch to HTML tab.

14 How to Create ASP Pages? 3.Add ASP codes into their respective places.

15 Reponse.Write ( ) Response object is the part of ASP that handles responding to the request of a browser If you want to display information to Web page Write method of the response object will be used. <% Response.Write(“Hello World”) %> NOTE : equal sign (=) is a short-cut of response.write object

16 How to Save ASP Pages? 4.Save your file with the extension.asp. Write asp extension with the file name. Select Active Server Pages option as file type. So, you do not need to write file extension. OR

17 How to transfer to the Server?

18 How to Display ASP Pages?

19 Another example! (“for – next”) We want to write “hosgeldiniz” in 5 different font size!

20 Handling HTML codes in ASP codes ” %> htmlTuna Tuna Tuna Tuna response.write “ Tuna “ typeMismatch

21 response.write response.write “ Tuna “ Handling Error: 1 st way: Do not use “ “ in HTML! But;  face = lucida ? <% response.write %> ? 2 nd way: use ‘ ‘ instead of “ “ Examples: Example 1:Adding 2 numbers <% num1 = 40 num2 = 30 response.write num1 + num2 %>

22 response.write Example 2:finding y <% num1 = 10 num2 = 20 sq1 = num1 * num1 sq2 = num2 * num2 sum = num1 + num2 response.write sq2 &","& sq1 & "," & sum Example 3:finding the square of 2 numbers and the addition of their square

23 response.write & if..then..else..end if Example 4:VAT included Price 0 THEN response.write num &" "& "is a positive number.“ ELSE response.write num &" "& "is a negative number.“ END IF %> Example 5:positive or negative?

24 response.write & if..then..else..end if Example 6: If a number less than 10, output it's square otherwise the number only. 10 THEN sq = num * num response.write sq ELSE response.write num END IF %> num2 THEN num = num1 - num2 ELSE num = num2 - num1 END IF Response.Write num %> Example 7: Subtract the smaller from the larger

25 response.write & if..then..else..end if Example 8: SNG room 100$ others 150$> Example 9: PASS, FAIL = 50 THEN Response.Write "PASS“ ELSE Response.Write "FAIL“ END IF %>