• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Junilu Lacar
Sheriffs:
  • Rob Spoor
  • Liutauras Vilda
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Piet Souris
  • Tim Holloway
  • Jj Roberts
  • Stephan van Hulst
Bartenders:
  • Himai Minh
  • Carey Brown
  • Frits Walraven

What is Ajax ?

 
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I would like to ask some basic questions about Ajax.

1) What is Ajax ?

2) How is it different from Java technology ?

3) What is the Use of it ?

4)How it will be helpful in performance tunning ?

I am working in a project in which they are planning to implement Ajax. Before that I need the information. A reply to this topic is appreciated.

Cheers,

-Biswa
 
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Biswa,

Please read through this information on this site. It should answer your questions.

http://en.wikipedia.org/wiki/AJAX

Eric
 
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Two other free websites with alot of information are Ajaxian and Ajax Patterns .

We have an Ajax audiobook available, the only available Ajax audiobook, but it is no longer free (although one sample track is available).
 
Author
Posts: 85
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
1) http://www.adaptivepath.com/publications/essays/archives/000385.php Ajax stands for Asynchronous JavaScript and XML. In a nutshell Ajax is the use of the XMLHttpRequest object to make HTTP requests in the context of a loaded HTML page. To change content you don't need to reload the page.

2) Ajax and Java conflict on the client side. Ajax uses Dynamic HTML, JavaScript, and XMLHttpRequest to create an HTML page that could be described as behaving like a traditional client application. Though it has to be said that Java can function completely as a stand-alone client. In most cases Ajax does interact with a server. The server would be generating content using either Java Servlet's or JSP's or something along those lines.

3) In the big scheme of things if you are happy coding a traditional Java client, then there is no reason to switch to Ajax. If however, you are leaning towards a Web application and want a better user experience then Ajax answers those questions. Ajax gives you all of the advantages of the Web, without (mostly) the user interface problems that the Web traditionally had.

4) Please clarify as I don't seem to understand the question?
 
Swosti Dipan Pal
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for the Reply.

We are getting a few XML from various webservices. We are using XSL to show up the info. However, it is taking a lot of time to show up the page. Will Ajax be a better option to reduce the time taken to show up the page ?

Cheers,
-Biswa
 
Christian Gross
Author
Posts: 85
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Oh, you are doing client side XSL? Ouch, that can hurt if the data set is large enough.

If you are getting your data in XML, and then doing an XSL transformation there are several things that can hurt. First the XSL transformation can be problematic, but so can the injection of the resulting HTML into the HTML page.

I would like to know what techniques are you using on the client side?

Using Ajax you may or may not get a performance boost. Using Ajax the following steps would be carried out.

1) Client makes XMLHttpRequest request
2) Web server sends XML data to client
3) XMLHttpRequest receives the data and if the data is marked as XML will generate an XML DOM (Performance point #1)
4) Client iterates XML DOM to find elements it wants (Peformance hit #2)
5) Client finds XML element instantiates new HTML objects or injects HTML text (Performance hit #3)

The performance hits might be less than running an XSLT transformation, but I would be wary of saying that you will get a massive performance increase.

Instead what I would do is implement an Infinite Data pattern strategy. Using the Infinite Data pattern strategy you are fed on a piecemeal basis the results. Doing a search of Google is an example of Infinite Data in that Google does not give you all of the results at once. You need to page through the results. And as you page through the results more content is generated.

If you want to exchange source code so that I can help you at a technical level send me a private message and we can continue from there.
 
All of the world's problems can be solved in a garden - Geoff Lawton. Tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
reply
    Bookmark Topic Watch Topic
  • New Topic