Download presentation
Presentation is loading. Please wait.
1
Web Platform Introduction With a focus on “free” Mike Taulty Developer & Platform Group Microsoft Ltd Mike.Taulty@microsoft.com http://www.mtaulty.com
2
The humble web request GET /default.html HTTP/1.1 200 OK... Internet Information Services V5 (2000), V6 (2003), V7* (2008) can develop without IIS ASP.NET adds.NET to HTTP handling
3
The humble web request GET /default.html HTTP/1.1 200 OK... Internet Information Services V5 (2000), V6 (2003), V7* (2008) can develop without IIS ASP.NET adds.NET to HTTP handling
4
Rest of the talk What’s.NET? Common aspects of ASP.NET Web Pages (.ASPX) Web Pages (.ASPX) Web Services (.ASMX) Web Services (.ASMX) Custom (.ASHX) Custom (.ASHX) Specific ASP.NET request handlers
5
Many languages, one framework Languages C# VB C++/CLI....NET Framework (The “class libraries”).NET Framework (The “class libraries”).NET Framework Core Services Threading I/O Network Collections Config... Diagnostics Security Resources Data XML Windows UI Web UI Workflow Comms void Foo() { MessageBox.Show("Hello World"); }
6
Many languages, one exe format.NET Assembly Metadata Code (CIL) compile void Foo() { MessageBox.Show("Hello World"); } C# Sub Foo() MessageBox.Show("Hello World") End Sub VB void Foo() { MessageBox::Show(L”Hello World”); } C++
7
Many languages, one runtime (CLR) Common Language Runtime (CLR) Class Loader IL to Native Compilers IL to Native Compilers Code Manager Code Manager Garbage Collector Garbage Collector Security Engine Debug Engine Type Checker Exception Manager Thread Support COM Marshaler Base Class Library Support.NET Assembly Metadata Code (CIL) Just In Time Native Code 0101010101 0100101011 Native Code 0101010101 0100101011 Verified? run
8
Versions of.NET Framework & Tools 2003 VS.NET 2003 Fx 1.1 VS.NET 2003 Fx 1.1 2002 VS.NET Fx 1.0 VS.NET Fx 1.0 2005 VS 2005 Fx 2.0 VS 2005 Fx 2.0 2006 Vista Fx 3.0 Vista Fx 3.0 2007 VS 2008 Fx 3.5 VS 2008 Fx 3.5.NET Framework is a free download Visual Studio comes in various editions Express, Standard, Professional, Team SQL Server also has an Express edition
9
Next... What’s.NET? Common aspects of ASP.NET Web Pages (.ASPX) Web Pages (.ASPX) Web Services (.ASMX) Web Services (.ASMX) Custom (.ASHX) Custom (.ASHX) Specific ASP.NET request handlers
10
Operation of built-in ASP.NET handlers GET /somefile.ext HTTP/1.1 200 OK... somefile.extuser codegen’d code associated with* produces*.NET Class compiled into instantiate & call to produce response Instance
11
GET /somefile.ext HTTP/1.1 200 OK... somefile.ext instantiate & call to produce response Instance.NET Class Operation of built-in ASP.NET handlers
12
ASP.NET Configuration All settings stored in XML files Applied hierarchically Library support Easy access to settings Easy extension to include custom settings machine.configweb.config /webSites/ site1 web.config
13
Next... What’s.NET? Common aspects of ASP.NET Web Pages (.ASPX) Web Pages (.ASPX) Web Services (.ASMX) Web Services (.ASMX) Custom (.ASHX) Custom (.ASHX) Specific ASP.NET request handlers
14
ASP.NET Web Pages Control-based framework for productive means of generating HTML Author a.ASPX file Use designer/text-editor to add controls, HTML and set properties Write Page class in code-behind
15
From text file to compiled code
16
From.ASPX file to compiled code GET test.aspx test_aspx generates & compiles System.Web.UI.Control controls collection System.Web.UI.Page ProcessRequest() void FrameworkInitialize() { controls.Add( new LiteralControl( “.......”)); } void FrameworkInitialize() { controls.Add( new LiteralControl( “.......”)); }
17
A page is a tree of controls Page Control render (HtmlWriter) Render()
18
A page contains a form
19
Pages (generally) post to “themselves” GET /default.aspx Page Control HTTP/1.1 200 OK... POST /default.aspx Post Data Page Control IsPostback = True
20
At post-back, controls fire events
21
Controls “appear” to maintain state GET /default.aspx POST /default.aspx Post Data POST /default.aspx Post Data (incl VIEWSTATE) Post Data (incl VIEWSTATE) Apply VIEWSTATE
22
Pages go through a life-cycle
23
Lifecycle of a Page (simplified) InitLoad Pre- Render RenderUnload CreateChildControls, ViewState loaded (for post-backs) CreateChildControls, ViewState loaded (for post-backs) Server-Side events fired (for post-backs) Server-Side events fired (for post-backs) CreateChildControls (for non-post-backs) CreateChildControls (for non-post-backs) ViewState saved
24
Page “Feature Areas” Features Data Binding LoginProfileNavigationValidationSessionCaching
25
Databinding
26
Next... What’s.NET? Common aspects of ASP.NET Web Pages (.ASPX) Web Pages (.ASPX) Web Services (.ASMX) Web Services (.ASMX) Custom (.ASHX) Custom (.ASHX) Specific ASP.NET request handlers
27
ASP.NET Web Services Providing SOAP request/response framework “Automatic” construction of XML, SOAP and WSDL description Author a.ASMX file Write service class in code behind Attribute service class with WebService and WebMethod
28
ASP.NET Web Services
29
Next... What’s.NET? Common aspects of ASP.NET Web Pages (.ASPX) Web Pages (.ASPX) Web Services (.ASMX) Web Services (.ASMX) Custom (.ASHX) Custom (.ASHX) Specific ASP.NET request handlers
30
ASP.NET Custom Handlers Lower level mechanism for producing any response to an HTTP request Author a.ASHX file Write handler class in code behind Use provided HttpContext object Request property Response property
31
ASP.NET Custom Handlers
32
Summary ASP.NET released since 2002 Plus in to all shipping IIS versions Best affinity with IIS7 in Windows Server 2008 Executes.NET code to process requests Specific framework for Pages with many high- level controls for building a site Specific framework for Services
33
© 2007 Microsoft Ltd. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.