AJAX
  Home arrow AJAX arrow Page 4 - The Ajax Approach to ACP: A Simple Example
Dev Shed Forums  
Administration  
AJAX  
Apache  
BrainDump  
DHTML  
Flash  
Java  
JavaScript  
Multimedia  
MySQL  
Oracle  
Perl  
PHP  
Practices  
Python  
Reviews  
Security  
Smartphone Development  
Style-Sheets  
Web Services  
XML  
Zend  
Zope  
Mobile Linux  
App Generation ROI  
IBM® developerWorks  
Forums Sitemap  
E-Commerce Hosting  
Linux Web Hosting  
Managed Hosting  
Small Business Hosting  
VPS Hosting  
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? 
Google.com  
AJAX

The Ajax Approach to ACP: A Simple Example
By: Chrysanthus Forcha
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: starstarstarstarstar / 4
    2008-10-21


    Table of Contents:
  • The Ajax Approach to ACP: A Simple Example
  • The Simple Example Code
  • The Script in the DIV in the BODY
  • The Back Button

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      error-file:tidyout.log Del.ici.ous error-file:tidyout.log Digg
      error-file:tidyout.log Blink error-file:tidyout.log Simpy
      error-file:tidyout.log Google error-file:tidyout.log Spurl
      error-file:tidyout.log Y! MyWeb error-file:tidyout.log 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


    The Ajax Approach to ACP: A Simple Example - The Back Button
    ( Page 4 of 4 )

    With the Ajax approach to ACP, the Back button of the browser is not enabled, no matter how many pages you display. This is because no window is changed. If you click the browser Refresh (Reload) button, you would have the very first page.

    If you need the Back and Forward buttons, then you should create you own. You can create them at the top-left corner inside your web page. You have to write code for them, so that when each one is clicked, the necessary page will be displayed (from the array). With the simple example we had, the pages are in string forms in the array in the master page. The functions for the buttons would be easy to write if the contents of the pages do not depend on one another.

    Rendering Web pages as they arrive

    With the Ajax approach to ACP, the first web page should be rendered as it arrives at the browser. If you design your web page according to normal CSS flow, it should be rendered by the browser as it arrives, everything being equal.

    The main problem occurs with HTML tables. If you want a table to be rendered as it arrives, declare column properties (e.g. widths) at the start of the table definition. Avoid the particular use of "0*" to specify column width. If you do not specify the column widths, the table may not be rendered incrementally, as it arrives.

    The secret lies in giving the table column widths values at the beginning of the table definition. The widths can be in pixels, percentage or proportionally e.g. width="3*".

    Advantages of ACP

    Before we end this part, let us recall the advantages of ACP.

    Any information stored at the server and its analysis can be presented quickly to the user with ACP, independent of whether the Internet connection is fast or slow. Only the first page may take some time to download through a slow Internet connection.

    Web pages are becoming voluminous because authors are putting a lot of script into them. This leads to lengthy download times. With ACP, downloads won't take so long.

    If you understand your scripting language very well, you will pay less for hosting since the analysis will now be done by your script at the client and not by some program at the server.

    ACP frees the server from work and so increases overall speed of the World Wide Web. If every client uses ACP, a client will not have to wait too long for the server to serve other clients before it is served, since the processing will be done at the client and not at the server. In other words, the server will spend less time serving a client. One of the aims of N-Tier systems is to free the server from work. ACP also serves that purpose.

    We will stop here and continue in the next part of the series.



     
     
    >>> More AJAX Articles          >>> More By Chrysanthus Forcha
     

       

    AJAX ARTICLES

    - PHP AJAX Form Validation
    - Completing a User-Defined CSS Website with P...
    - Create a User-Defined CSS Website with PHP
    - Build A Better Twitter Chat Client Than Cham...
    - Using Division Equations to Make Web Forms S...
    - Using Integer Multiplication to Protect Web ...
    - Using Simple Checksums for Web Form Verifica...
    - Protecting Web Forms with AJAX
    - Using Prototip with AJAX
    - Using Prototip
    - Using the google.load() Method with Google`s...
    - How to Handle Ajax Errors
    - Uncompressing Source Files with Google`s AJA...
    - Using the jQuery Framework with Google`s Aja...
    - Using Google`s Ajax Libraries API




    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 6 Hosted by Hostway
    For more Enterprise Application Development news, visit eWeek