ASP.NET
  Home arrow ASP.NET arrow Page 2 - Three Patterns of Constructing an ASP.NET ...
ASP Free Forums 
.NET  
ASP  
ASP Code  
ASP.NET  
ASP.NET Code  
BrainDump  
C#  
Code Examples  
Database  
Database Code  
IIS  
Microsoft Access  
MS SQL Server  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
ASP Web Hosting  
ASP.NET Web Hosting 
Mobile Linux 
App Generation ROI 
Windows Web Hosting
 
IBM® developerWorks 
Sun Developer Network 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
ASP.NET

Three Patterns of Constructing an ASP.NET AJAX-based Applications
By: Xianzhong Zhu
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 3
    2007-07-17

    Table of Contents:
  • Three Patterns of Constructing an ASP.NET AJAX-based Applications
  • Choosing the Pattern Most Suitable for You
  • Function and Architecture Overview
  • Enable ASP.NET AJAX Support for JSSK

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    Three Patterns of Constructing an ASP.NET AJAX-based Applications - Choosing the Pattern Most Suitable for You


    (Page 2 of 4 )

    With the short analysis above, we can divide all the scenarios based on the MS AJAX framework into three typical patterns, as generalized below.

    1. Rebuilding a legacy ASP.NET 2.0 application.

    Obviously, there exist tons of legacy ASP.NET 2.0 applications around us; this even includes older applications reconstructed for ASP.NET 2.0. Some of them hold features that can benefit from being enhanced with AJAX, such as adding an automatically populating function to some TextBox controls, locally updating areas that often change, and so forth. Since the MS AJAX client-side solution is pretty distinct from that of the ASP.NET 2.0 server side and we are unwilling to rewrite the current entire project with full functions, we have to rebuild them using the MS AJAX server-side solution. Luckily, this kind of pattern requires only a little effort, without even a line of code. By merely adding an ASP.NET 2.0 server-side Extender control you can "ajaxify" your legacy projects elegantly. We won't dwell much on this because later on we'll examine a lengthy sample introducing this solution.

    2. Creating a "sheer'"AJAX application from scratch.

    "Sheer" AJAX applications refer to those for which there is no presentation tier logic performed on the server side except for the data, while all the presentation logic is accomplished through the client-side JavaScript programming. A typical example is one of Microsoft's latest products -- Windows Live Mail, all of whose functions (including users input, communication with the server side, user interface alteration, etc.) are performed on the client side. Undoubtedly, this contrasts sharply with our familiar ASP.NET development pattern; however, it will result in outstanding server-side performance and clearer application architecture. In such scenarios, we should, as a top priority, take into consideration this kind of solution.

    3. Constructing web applications running on non-ASP.NET 2.0 server-side platforms.

    When you plan to develop web applications that run on non-ASP.NET 2.0 server-side platforms, we have to consider the MS AJAX client-side solution. A typical example is the PHP case as mentioned above.

    Well, for now, I guess you may have already singled out your favorite routine for your ASP.NET AJAX journey. However, you should notice that the two modes (server-centric vs. client-centric) mentioned above are not absolutely opposite but supplement each other. This means that in a real development scenario we just lay emphasis on one side, such as in the case of the "sheer" MS AJAX pattern; we still need the server-side control-ScriptManager to send the necessary JavaScript files that the MS AJAX client side requires.

    So much for the discussion of theory. Let's roll up our sleeves to create a vivid sample. Here, we will exemplify the first kind of solution by ajaxifying the famous Microsoft Job Site Starter Kit.

    Ajaxifying the Microsoft Job Site Starter Kit

    As one of the famous Microsoft Starter Kit samples, the Job Site Starter Kit ("JSSK" for short) provides a platform for candidates seeking a job and employers seeking an employee to share their needs. Why did we select this starter kit as an example? The reason lies mainly in two aspects. On the one hand, the starter kit demonstrates many new and typical features of ASP.NET 2.0 including themes, master pages, new data controls, membership, roles and profiles. On the other hand, this starter kit lays its emphasis on the implementation of the presentation tier, i.e. utilizing rich controls such as GridView, DetailsView, TreeView, WebPart, and User Controls, which can put the ASP.NET AJAX server-side controls (including ASP.NET AJAX Control Toolkit) to good use. In addition, JSSK holds a comparatively simple logic tier, so that we will concentrate on the controls of the presentation tier.

    Author's Note: To help beginners quickly familiarize themselves with JSSK, JSSK provides three initial users with three different types of roles introduced in this sample. They are named "ravi" (with the password "pass$word" and playing the role of employer), "alok" (with the same password and playing the role of job seeker), and "admin" (with the password "admin" and playing the role of administrator) respectively. Here, for brevity, we omit the entire detailed introduction to JSSK, including the download and install process (all pretty easy), while we still cover a bit about JSSK associated with the necessary parts we're going to explore.

    More ASP.NET Articles
    More By Xianzhong Zhu


     

    ASP.NET ARTICLES

    - Advantages of the ASP.NET MVC Approach
    - ASP.NET Web Forms Weaknesses
    - ASP.NET Web Forms Meets ASP.NET MVC
    - Source Code for Saving and Retrieving Data w...
    - Using GridView to Save and Retrieve Data wit...
    - Handling Dynamic Images in ASP.NET 3.5 AJAX ...
    - Retrieving Data with AJAX and the GridView C...
    - Playing with Images in ASP.NET 3.5 AJAX Appl...
    - Saving and Retrieving Data with AJAX
    - Enhancing PHP Via the ASP.NET AJAX Framework...
    - Enhancing PHP Programming with the ASP.NET A...
    - Classes and ASP.NET AJAX
    - Using ASP.NET AJAX
    - Building a Simple Storefront with LINQ
    - Developing a Dice Game Using ASP.NET Futures...





    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway
    Stay green...Green IT