Session 1
-
Upload
baker-nolan -
Category
Documents
-
view
19 -
download
1
description
Transcript of Session 1
Building Applications using ASP.NET and C# / Session 1 / 2 of 21
Session ObjectivesSession Objectives Describe the following -
• Web application• Web application development cycle
Explain Active Server Pages
Explain the features of ASP.NET
Building Applications using ASP.NET and C# / Session 1 / 3 of 21
ActiveX Data Objects(ADO)
ActiveX Data Objects(ADO)
DatabaseDatabase
Client 1 (Browser)
Client 2 (Browser)
Client 1
Client 2
Client/Server and Client/Server and Web ApplicationsWeb Applications
Building Applications using ASP.NET and C# / Session 1 / 4 of 21
Web-enabled Application ArchitectureWeb-enabled Application Architecture
Proxy ServerProxy Server
Internet
Internet
Database
Server
Web server
HTTP
Web server
HTTP
Certificate Server
Server-based programsASPCGIISAPI
Server-based programsASPCGIISAPI
Other serversFTPSMTPExchange Server
Other serversFTPSMTPExchange Server
Client 1 (Browser)
Building Applications using ASP.NET and C# / Session 1 / 5 of 21
HTTP at workHTTP at work
Client (Browser)
Client (Browser)
Send me “Introduction to
Hypertext”
Send me “Introduction to
Hypertext”
Page Request
Introduction to Hypertext
Building Applications using ASP.NET and C# / Session 1 / 6 of 21
Network Interface Network Interface and HTTP Serviceand HTTP Service
Network Interface
Transport Layer andInternet Layer
(TCP / IP)
Windows Sockets
HTTP FTP
Internet
Building Applications using ASP.NET and C# / Session 1 / 7 of 21
Accessing Database Accessing Database InformationInformation
InternetClient (Browser)
ODBCDatabase
ServerDatabase
Server
Web server
HTTP
Web server
HTTP
Building Applications using ASP.NET and C# / Session 1 / 8 of 21
Web Application Web Application Development CycleDevelopment Cycle
Designing the application Designing the application
Constructing and testing the components of the applicationConstructing and testing the components of the application
Going live Going live
Production and Maintenance Production and Maintenance
Planning the Web application
Building Applications using ASP.NET and C# / Session 1 / 9 of 21
Web Application Web Application Development Development
ProcessProcess
Functional Specifications
complete?
Functional Specifications
complete?No
Design PhaseDesign Phase
Design complete?
Design complete?
Planning PhasePlanning Phase
Yes
Construction and Testing
Construction and Testing
Complete?Complete?
Going LiveGoing Live
Production and Maintenance
Production and Maintenance
AA
AA
No
Yes
No
Yes
Building Applications using ASP.NET and C# / Session 1 / 10 of 21
ScriptingScriptingData entry
ProcessingProcessingWeb Server: CGI Scripts
Web Server: CGI Scripts
Web client: Browser
Processing
Data entry
ProcessingProcessing
Web Server: CGI Scripts
Web Server: CGI Scripts
Web client:Browser
JavaScript VBScript
Building Applications using ASP.NET and C# / Session 1 / 11 of 21
Validating DataValidating Data
HTML FormHTML Form
User inputUser input
JavaScript data validation
JavaScript data validation
Data valid?
Valid DataValid DataSubmit data
to serverSubmit data
to server
Yes
No
Building Applications using ASP.NET and C# / Session 1 / 12 of 21
Client-Side Client-Side ScriptingScripting
Provide user interaction
Dynamically change content
Validate data
Integration
<script language="JavaScript"><!--JavaScript statements;//--></script>
Specifies the scripting language
comment tags
Building Applications using ASP.NET and C# / Session 1 / 13 of 21
Active Server Active Server PagesPages
<HTML><BODY><CENTER><I><FONT COLOR="HOTPINK" size = 5><%If Time >= #12:00:00 AM# And Time < #12:00:00 PM#
Then%> "Now the time is between 12:00 am and 12:00 pm"
<%Else%>" Now the time is between 12:00 pm and 12:00 am"
<%End If%></FONT></I></CENTER></BODY></HTML>
Executed on server
Building Applications using ASP.NET and C# / Session 1 / 14 of 21
Processing of ASP Processing of ASP filefile
Client (Browser)
ASP.DLLASP.DLL
IISIISVBScriptVBScript
JavaScriptJavaScript
ActiveX Data Objects
(ADO)
ActiveX Data Objects
(ADO)
DatabaseDatabase ASP file
Building Applications using ASP.NET and C# / Session 1 / 15 of 21
Advantages of ASPAdvantages of ASP
Building Applications using ASP.NET and C# / Session 1 / 16 of 21
ASP file in a Web-ASP file in a Web-based applicationbased application
Client (Browser)
Active Server
Components
Active Server
Components
DatabaseDatabase
Active Server Pages (ASP)
•JavaScript•VBScript
Active Server Pages (ASP)
•JavaScript•VBScript
Active Server Pages (ASP)
•JavaScript•VBScript
Active Server Pages (ASP)
•JavaScript•VBScript
Active Server Pages (ASP)
•JavaScript•VBScript
Active Server Pages (ASP)
•JavaScript•VBScript
Building Applications using ASP.NET and C# / Session 1 / 17 of 21
Evolution of Evolution of ASP.NETASP.NET
Building Applications using ASP.NET and C# / Session 1 / 18 of 21
Drawbacks of ASPDrawbacks of ASP
Interpreted ASP pages
Only two non-typed languages VBScript and JavaScript
Spaghetti-like mixture of code, HTML and text
Using the same file.
Extra code for functionality
No Re-usage of code
No debugging mechanism
Shut down of web server to install a new version of a DLL
Building Applications using ASP.NET and C# / Session 1 / 19 of 21
Advantages of Advantages of ASP.NETASP.NET
ASP.NETASP.NET
Supports strongly typed languages like C#, VBSupports strongly typed languages like C#, VB
Compiled pages improving execution speed Compiled pages improving execution speed
Supports re-use of code by the mechanism of inheritance Supports re-use of code by the mechanism of inheritance
ASP code is separated from the HTML design and textASP code is separated from the HTML design and text
Provides server controls that are declarative Provides server controls that are declarative
An inbuilt method Trace, helps in debugging a page An inbuilt method Trace, helps in debugging a page
No need to register component. No need to register component.
Building Applications using ASP.NET and C# / Session 1 / 20 of 21
Features of Features of ASP.NET - 1ASP.NET - 1
ASP.NETASP.NET
Recognizes the type of client browser and accordingly display the contents to the client. Recognizes the type of client browser and accordingly display the contents to the client.
Adds functionality using C# or VB.NET Adds functionality using C# or VB.NET
Uses server - side caching Uses server - side caching
Ships with many built-in server controlsShips with many built-in server controls
Building Applications using ASP.NET and C# / Session 1 / 21 of 21
Features of Features of ASP.NET - 2ASP.NET - 2
Refers hierarchical namespaces. Refers hierarchical namespaces.
Global.asax file holds additional eventsGlobal.asax file holds additional events
Web service - a function deployed and used over the webWeb service - a function deployed and used over the web
ASP.NETASP.NET