Introduction.NET and especially ASP.NET development is providing a revolutionary platform for Web development. The ease of debugging an ASP.NET page is truly a killer feature and time-saver for any Web developer. Reusable controls allow for much quicker Web development because they can be used all throughout the site. For example, you can create a navigation user control to navigate through your site and easily include this on every Web page on your site. This not only speeds up development but also isolates the code to one central location. User controls also allow for site redesign like no other Web development platform out there. Validation controls allow for collection of more accurate data on your site. If you are asking for user information such as addresses, zip codes, and the like, you should be using ASP.NET's Validation controls. Through the use of Regular Expressions, many of these informational pages that are so common to Web sites are there out of the box! Not to mention that ASP.NET allows for development in many different languages (C#, VB.NET, MC++, etc.)!With the next release, ASP.NET 2.0 (see http://www.asp.net/whidbey), the ASP.NET team has reduced the amount of coding required for a normal Web site drastically, in some cases up to 70%! That has got to be the most amazing feature of all. They have added to all the out-of-the-box User controls and Validation controls and created a new concept of Master pages, which is pretty much the equivalent to skinning a Web site!Of course there is way too much to say about ASP.NET that is beyond the scope of this chapter. For a great book on ASP.NET, see:Essential ASP.NET with Examples in C# By Fritz Onion Addison-WesleyThe ASP.NET team has created a great balance of stateless server-side controls. Server-side controls run most of the server-side code, except for validation, which is BOTH server-side and client-side JavaScript for added security, which allows for the greatest multiple browser support. To achieve all the benefits of server-side controls (ease of debugging, rich user interface controls, multiple output targets, and a similar event model to Windows Forms development, just to name a few) did not come without cost. The magic behind the curtain is found mainly in the ASP.NET ViewState tag. This hidden tag, shown in Listing 11.1, holds information for all server-side controls in an ASP.NET page. Listing 11.1. ASP.NET ViewState<input type="hidden" name="__VIEWSTATE" value="dDwtMTkxNTA2MjkwNzt0PDtsPGk8MD47PjtsPHQ8O2w8aTw3PjtpPDE1Pjs+O2 w8dDxwPHA8bDxOYXZpZ2F0ZVVybDs+O2w8V2lraS5hc3B4P3BhZ2U9V2lraUhvbWU7Pj47c DxsPG9ubW91c2VvdmVyO29ubW91c2VvdXQ7PjtsPHJldHVybiBvdmVybGliKCdSZW ZyZXNoIGN1cnJlbnQgcGFnZScsQ0FQVElPTiwnV2lraSBHdWlkZScpXDs7cmV0dXJuIG 5kKClcOzs+Pj47Oz47dDxwPHA8bDxUZXh0Oz47bDxXaWtpSG9tZTs+Pjs+Ozs+Oz4+Oz 4+Oz7AZtEwI0N/q3zFypouwKCIFvwErw==" /> Chapter 10 and expand it into a cross-platform Web service that can run on multiple operating systems. Also an ASP.NET page will be created to run a simple query on the Web service. |