AJAX
  Home arrow AJAX arrow Page 3 - An Enhanced Ajax Approach to Active Client Pages
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? 
AJAX

An Enhanced Ajax Approach to Active Client Pages
By: Chrysanthus Forcha
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: starstarstarstarstar / 7
    2008-10-28


    Table of Contents:
  • An Enhanced Ajax Approach to Active Client Pages
  • The DOM Table
  • The innerHTML Property
  • The HTML OBJECT Element
  • Summing Up

  • 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


    An Enhanced Ajax Approach to Active Client Pages - The innerHTML Property
    ( Page 3 of 5 )

    Now that you are producing the content at the client, it might interest you to be able to change the content of HTML elements. You probably already knew that you could change the table cell content with the innerHTML property. Many browsers today allow you to change the content of almost any HTML element.


    Consider the following code:


    <html>

    <head>

    <script type="text/javascript">

    function changeContent()

    {

    document.getElementById('S1').innerHTML = "two";

    document.getElementById('D1').innerHTML = "second";

    }

    </script>

    </head>

    <body>

    <span id="S1">one</span>

    <div id="D1">First</div>

    <button type="button" onclick="changeContent()">Click</button>

    </body>

    </html>

    When you click the button, the contents of the SPAN and DIV elements will be changed by the function in the script. This is just to show you that, as your web pages or forms would be produced at the client, you may have to change the contents of HTML elements. This feature is not imperative for ACP. It comes as a complement. You can try the above code.

    Images

    Ajax is used to obtain a string from the server or an XML document without the user being conscious of the process. So in ACP, Ajax cannot help us to obtain images in advance. However I discovered that the HTML OBJECT element could download images in advance. This is a subject for a different article; however see the introduction I give on the next page.




     
     
    >>> 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 4 Hosted by Hostway
    Stay green...Green IT