The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which...
-
Upload
karen-sherman -
Category
Documents
-
view
214 -
download
0
Transcript of The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which...
![Page 1: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/1.jpg)
The Web Architecture and ASP.NET
![Page 2: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/2.jpg)
Slide 2
Review of the Web (1) It began with HTTP and HTML, which
delivers static Web pages to browsers which would render those pages
Browser Web Server
HTTP Request
HTTP Response(Web page)
![Page 3: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/3.jpg)
Slide 3
Review of the Web (2) Scripting languages were created to
execute client code within the context of a browser
Browser
Web Server
HTTP Request
HTTP Response(Web page / code)
Client code (JavaScript)(VBScript)
![Page 4: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/4.jpg)
Slide 4
Review of the Web (3) Server-side applications were created to
execute code and dynamically generate Web pages based on a particular requestBrowser Web Server
HTTP Request
HTTP Response(Web page / code)
Client code
(script)
Interpret request
Generate HTML and
script
![Page 5: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/5.jpg)
Slide 5
Review of the Web (4) And now we have AJAX / JSON making
partial page requests
Browser
Web Server
HTTP Request
HTTP Response(Web page / code)
Client code (script)
Interpret request
Generate HTML and
script
Execute AJAX Request
Client code (Silverlight)
![Page 6: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/6.jpg)
Slide 6
The Great Client/Server Debate Where do we process?
Client or server What get’s processed where? And the interaction between client and
server
Where does bandwidth fit into this equation? Where does processing power (and latency)
fit into this equation?
![Page 7: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/7.jpg)
Slide 7
And all the Related Technologies jQuery – yes it works with ASP AJAX – ASP has some interesting AJAX
libraries We can (AND WILL) write our own handlers for
those AJAX requests Silverlight is a well-used client-side
framework part of RIA (http://msdn.microsoft.com/en-us/library/ee707344(v=vs.91).aspx)
Azure?
![Page 8: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/8.jpg)
Slide 8
Current Client Technologies And what browser (and version) do
you use? Scripting details vary from browser to
browser DOM objects can vary a bit too HTML5 and CSS3 support varies but is
pretty good
![Page 9: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/9.jpg)
Slide 9
Current Server Technologies Apache WebSphere (IBM) Oracle / Sun (doing ASP.NET, CGI and PHP) Microsoft and IIS HP and others have offerings
Largely based on Apache
In summary, there are quite a few
![Page 10: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/10.jpg)
Slide 10
ASP.NET (History) Introduced with the .NET Framework in
2002 It made Web development look like traditional
Windows development ASP.NET 2.0 introduced in 2005 gave
developers enhanced database tools This included desktop improvements too MVC was introduced / much more later
ASP.NET 3.0 released with 2008
![Page 11: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/11.jpg)
Slide 11
ASP.NET (History) ASP.NET 4 released with Visual Studio
2010 and version 4 of the Framework Razor was introduced along with ASP.NET
Web pages Web pages and Web Forms are different
There is an open-source movement (We will see how this pans out)
Support for HTML 5 and CSS 3 is very good
![Page 12: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/12.jpg)
Slide 12
ASP.NET (History) Current version is Visual Studio 2013
and Framework version 4.5.1
![Page 13: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/13.jpg)
Slide 13
ASP.NET (Architecture)
![Page 14: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/14.jpg)
Slide 14
What is a .NET Application (1)?
It looks and works surprisingly like Java Source code (VB, C#, etc.) is compiled into
a machine independent assembly language (MSIL or IL)
The executable file is called an assembly
IL can be disassembled using the IL Disassembler (ILDASM)
![Page 15: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/15.jpg)
Slide 15
What is a .NET Application (2)?
MSIL is translated into native executable code via the Just-in-Time (JIT) compiler It’s possible to precompile an application
using the Native Image Generator (Ngen) All .NET applications run under the control of
the Common Language Runtime (CLR) We call this managed code
![Page 16: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/16.jpg)
Slide 16
What is a .NET Application (3)?
On the desktop, the application runs under the control of the Common Language Runtime
With Respect to Web applications, all execution is handled on the server (IIS)
http://msdn.microsoft.com/en-us/library/bb470252.aspx
![Page 17: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/17.jpg)
Slide 17
The ASP.NET Runtime When IIS sees an .aspx file, it loads
aspnet_isapi.dll to create the Page object Application behavior is controlled by
configuration files Machine.config is the global machine
configuration file Web.config allows you to override default
configuration items Both are XML documents
![Page 18: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/18.jpg)
Slide 18
Programming ASP.NET Conceptually it’s much like the VB
programming you are used to You create procedures in event handlers
and general procedures You declare variables
Instead of a form, the primary user interface is the WebForm
![Page 19: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/19.jpg)
Slide 19
Current ASP Technologies ASP Web Forms
Have been around for a while and have continued to evolve
ASP.NET MVC It stands for Model-View-Controller It’s an alternative to Web Forms
ASP.NET Web Pages (Razor) A more lightweight processing model Looks a bit like PHP
Silverlight and RIA
![Page 20: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/20.jpg)
Slide 20
ASP.NET Web Forms Provides server-side tools for site navigation
Menus, Drill-down toolbars, breadcrumbs, etc. Authentication tools Database connections Client and server executable code State management and caching Authentication and role management Deployment tools Robust development tools (Visual Studio)
![Page 21: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/21.jpg)
Slide 21
ASP.NET Web Forms (Introduction)
Client (browser)
HTTP Server
(IIS)
ASP Worker
Process request
Generate client page (HTML)
request
response
![Page 22: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/22.jpg)
Slide 22
Web Forms and Stateful Web Programming Remember that the Web is stateless
Web servers to not persist state from one request to the next
ASP.NET does allow stateful programming though various hidden fields and serialized data server side session objects
Much more on state management later
![Page 23: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/23.jpg)
Slide 23
Web Forms and Event-Driven programming ASP.NET, though serialization, simulates
event-driven programming ASP.NET events differ significantly from
Windows Forms events
![Page 24: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/24.jpg)
Slide 24
Introduction to the Web Forms Component Model Remember that .NET is an OOP environment
and ASP.NET is no exception As the developer, you create .aspx pages that
make up a Web application When executed, the .aspx page is compiled into
a custom class that inherits from System.Web.UI.Page
As the developer, you can program against this class just as you would program against any class
It all happens on the server!
![Page 25: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/25.jpg)
Slide 25
ASP.NET MVC MVC is the acronym form Model-View-
Controller It’s a design pattern coined by the GOF
It requires version 4 of the .NET Framework
It’s an alternative to traditional ASP.NET Web forms
![Page 26: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/26.jpg)
Slide 26
Web Matrix and Razor A “lightweight” technology to create
simple Web sites Requires version 4.0 of the .NET
Framework and a few add-ins
![Page 27: The Web Architecture and ASP.NET. Slide 2 Review of the Web (1) It began with HTTP and HTML, which delivers static Web pages to browsers which would render.](https://reader034.fdocuments.in/reader034/viewer/2022042718/56649eac5503460f94bb23ac/html5/thumbnails/27.jpg)
Slide 27
Silverlight It run on a client (browser) and
communicates with a server via RIA services Netflix?