MSSQL & ASP. Client-Server Relationship Client-Server Relationship HTML Basics HTML Basics Scripting Basics Scripting Basics Examples Examples.

Slides:



Advertisements
Similar presentations
Dreamweaver Forms Overview. Forms – A Little Review Most user/webpage communication is one way, like this: Most user/webpage communication is one way,
Advertisements

Session Variables Storing Session Variables on the Server.
JavaScript FaaDoOEngineers.com FaaDoOEngineers.com.
Languages for Dynamic Web Documents
How to Make a Web Page: A Crash Course in HTML programming.
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.
Mark Dixon, SoCCE SOFT 131Page 1 20 – Web applications: HTML and Client-side code.
Creating Web Page Forms. Objectives Describe how Web forms can interact with a server-based program Insert a form into a Web page Create and format a.
Tutorial 6 Working with Web Forms
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.
4/8/99 C. Edward Chow Page 1 Active Server Page It is a server-side scripting environment for creating dynamic content. ASP are files with.asp extension,
Multiple Tiers in Action
CM143 - Web Week 2 Basic HTML. Links and Image Tags.
Tutorial 6 Working with Web Forms. XP Objectives Explore how Web forms interact with Web servers Create form elements Create field sets and legends Create.
2/22/00J. Alberto Espinosa -- CMU/GSIA MIS Dynamic HTML Using Active Server Pages (ASP) Alberto Espinosa MIS
Computer Science 101 Web Access to Databases Overview of Web Access to Databases.
CGI Programming: Part 1. What is CGI? CGI = Common Gateway Interface Provides a standardized way for web browsers to: –Call programs on a server. –Pass.
Creating Web Page Forms
Form Handling, Validation and Functions. Form Handling Forms are a graphical user interfaces (GUIs) that enables the interaction between users and servers.
McGraw-Hill/Irwin © 2004 by The McGraw-Hill Companies, Inc. All rights reserved. Beginning Active Server Pages Barry Sosinsky Valda Hilley Programming.
1 Web Developer & Design Foundations with XHTML Chapter 6 Key Concepts.
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
Application Development Description and exemplification of server-side scripting language for server connection, database selection, execution of SQL queries.
Server- Side technologies Client-side vs. Server-side scripts PHP basic ASP.NET basic ColdFusion.
XP Tutorial 6New Perspectives on HTML and XHTML, Comprehensive 1 Creating Web Page Forms Designing a Product Registration Form Tutorial 6.
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"
DAT602 Database Application Development Lecture 14 HTML.
ASP.NET Dr. Ralph Westfall May, Web Development Problem HTML designed to display static pages only interactive when user clicks links  can’t provide.
Dr. Azeddine Chikh IS444: Modern tools for applications development.
Server-side Scripting Powering the webs favourite services.
4-1 INTERNET DATABASE CONNECTOR Colorado Technical University IT420 Tim Peterson.
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.
.Net is a collection of libraries, templates and services designed to make programming applications of all kinds, easier, more flexible (multi platform),
Tutorial 10 Adding Spry Elements and Database Functionality Dreamweaver CS3 Tutorial 101.
Server Side Programming ASP1 Server Side Programming Database Integration (cont.) Internet Systems Design.
1 PHP and MySQL. 2 Topics  Querying Data with PHP  User-Driven Querying  Writing Data with PHP and MySQL PHP and MySQL.
Copyright © 2008 Pearson Prentice Hall. All rights reserved. 1 Exploring Microsoft Office Word 2007 Chapter 8 Word and the Internet Robert Grauer, Keith.
Web Programming: Client/Server Applications Server sends the web pages to the client. –built into Visual Studio for development purposes Client displays.
Client Scripting1 Internet Systems Design. Client Scripting2 n “A scripting language is a programming language that is used to manipulate, customize,
Tutorial 7 Creating Forms. Objectives Session 7.1 – Create an HTML form – Insert fields for text – Add labels for form elements – Create radio buttons.
Creating Dynamic Web Pages Using PHP and MySQL CS 320.
IS 4506 Interactive Clients & Servers.  Overview Fat Client versus Fat Server Spectrum of Web content formats Active Server Pages Active Server Page.
Website Development with PHP and MySQL Saving Data.
CHAPTER 7 Form & PHP. Introduction All of the following examples in this section will require two web pages. The first page retrieves information posted.
VBScript. Introduction Visual Basic scripting language is client side scripting language. It is developed by Microsoft VBScript is subset of VB language.
Tutorial 6 Working with Web Forms. XP Objectives Explore how Web forms interact with Web servers Create form elements Create field sets and legends Create.
Tutorial 6 Working with Web Forms. 2New Perspectives on HTML, XHTML, and XML, Comprehensive, 3rd Edition Objectives Explore how Web forms interact with.
Introduction to JavaScript CS101 Introduction to Computing.
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.
Web Design and Development. World Wide Web  World Wide Web (WWW or W3), collection of globally distributed text and multimedia documents and files 
Module: Software Engineering of Web Applications Chapter 2: Technologies 1.
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
Tutorial 6 Working with Web Forms. 2New Perspectives on HTML, XHTML, and XML, Comprehensive, 3rd Edition Objectives Explore how Web forms interact with.
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 Authoring with Dreamweaver. Unit Objectives  Be able to define keywords: HTML, HTTP (protocol), browser, web server, client/server, tag, attribute,
JavaScript 101 Introduction to Programming. Topics What is programming? The common elements found in most programming languages Introduction to JavaScript.
January 27, 2001ASP Basics1 Active Server Pages (ASP) Basics The client/server model Objects Forms Active Server Pages VBScript Lab and Homework.
Higher Computing Science Coding the Web: HTML, JavaScript, PHP and MySQL.
What is AJAX ? Asynchronous Javascript and XML. Not a stand-alone language or technology. It is a technique that combines a set of known technologies in.
HTML-I Basic HTML Elements. HTML (Hyper Text Markup Language) HTML is a document layout and hyperlink- specification language. i.e. a language used to.
1 CSC160 Chapter 1: Introduction to JavaScript Chapter 2: Placing JavaScript in an HTML File.
Unit 4 Working with data. Form Element HTML forms are used to pass data to a server. A form can contain input elements like text fields, checkboxes, radio-buttons,
Project 1 Introduction to HTML.
Introduction to Dynamic Web Programming
Active Server Pages Computer Science 40S.
Chapter 2 Client/Server Applications
Database Driven Websites
Client side & Server side scripting
IS 4506 Interactive Clients & Servers
Presentation transcript:

MSSQL & ASP

Client-Server Relationship Client-Server Relationship HTML Basics HTML Basics Scripting Basics Scripting Basics Examples Examples

Client-Server Relationship Client – user of an application –Sends requests to the server for a specific tasks (process data, obtain data, etc) –Uses HTML to tell web browser how to display data

Client-Server Relationship Server – more specifically, ASP (Active Server Pages) –Receives requests from the client to perform a certain task –Processes data and sends results back to the client –Uses scripting languages to process data (VBScript,PHP,JavaScript)

HTML Basics HTML performs two essential tasks 1.Displays data 2.Submits data to be process

HTML Basics Tags –HTML uses tags to format data –Tag Format: Some text here (optional) </command> –Save in a text editor (or web editor like Dreamweaver) and open with IE, Netscape, etc.

HTML Basics Example:<html><body> This is a paragraph. This is a paragraph. Paragraph elements are defined by the p tag. Paragraph elements are defined by the p tag. </body></html>

HTML Basics Common tags – - starts all documents – - all text is placed here – - links to other pages. Example: This is a Link This is a Link –,, - formats data in table form – - allow the user to enter information (explained in next slide) –Other tags -

HTML Basics Forms - A form is defined with tag Structure:<form> </form>

HTML Basics Form Example: Username: </form> –When user selects the “submit” button, the information in the form is submitted to the page “html_form_action.asp”. Other form elements:

VB Script Basics VB Scripts –Lightweight version of Visual Basic programming language –Can be placed anywhere in html code –Run by server and sent back to client –<% denotes beginning of the script –%> denotes end of script –Files with.asp extension will hold scripts (usually)

VB Script Basics Example Script: (saved as “example1.asp”) <html><body><% dim name name="John Harney" Response.write("My name is: " & name & “ ”) %></body></html> –Dim – dimensions a variable (can be any type) –Response.write – writes html content to the html page –Response Examples: – _response.asp

VB Script Basics Example Form: (saved as “example2.html”) <html><body> Grade: </form></body></html> –Form is “posted” to “example2.asp” with the text information “grade” when the user clicks submit

VB Script Basics Example Form: (saved as “example2.asp”) <html><body><% Dim grade entry = Request.Form("grade") If entry > 90 Then Response.write " You have an A " Response.write " You have an A " elseif entry > 80 Then elseif entry > 80 Then Response.write " You have a B " Response.write " You have a B " elseif entry > 70 Then elseif entry > 70 Then Response.wrtie " You have a C " Response.wrtie " You have a C " else else Response.write " You have an F " Response.write " You have an F " End If %></body></html> –Request.Form is the “posted” information from the form in “example2.html” –“grade” is the name of the text that was submitted

ASP ASP –Combines html and scripting with a database –Accesses the database and uses the information in data processing

ASP ASP – commands for accessing database <% set adocon = server.CreateObject("ADODB.Connection") set adorec = server.CreateObject("ADODB.recordset") adocon.Open("dsn=cscmssql1; uid=username; pwd=password;") adorec.ActiveConnection=adocon%> After connection is made, enter the sql command and use it: After connection is made, enter the sql command and use it:<% sqlText = “select * from database” Adocon.Open sqlText %>

ASP ASP Example – Sporting Goods Retailer –Contains the following 3 tables: Product (prodID,name,quantity,cost) Customer (custID,name,cardNo) Cp (custID,prodID)

References – HTML,VB,ASP – ASP validation and cookies Mathematical Science Database Page Office: Bryan 384 (W F 1-5)