Oracle Magazine Special offer for AjaxImpact.com Visitors!! Subscribe to Oracle Magazine for Free!
AJAX IMPACT


TUTORIALS
Implement Easy AJAX Chat using Java Servlet
05/08/2006 By Sinkmyship.com


There is a lot of AJAX chats popping out, the reason: it is very simple to automate communication between client (AJAX part) and with java, it is easy to distribute messages between clients in server-side. I will show you the implementation used in SMS chat’s.

There are several niceties that everyone includes such as enter key interception and refocusing on the chat entry field, for examples of either, just look at the source attached. The server side in Java is just as easy.

Since servlets are created once per application, you can use init method to instantiate a chat holding String or a Buffer (or any other self created object). Since this object will be automatically shared per any request to the servlet, you just add messages to it and post back to each requestor. Synchronization can be implemented as and if needed.

Download Chat.js sample: Chat.js

Download Servlet sample: ChatHandlerServlet.java

   Read Full Tutorial ...

 Rate this Ajax Tutorials
 Rating: 7.0 out of 57 votes cast

AJAX NEWS
05/15/2009 A tutorial on Prototype, Google Maps API and the HeatMapAPI
05/15/2009 The World's Most Popular Programming Language Has Fashion and Luck to Thank
05/09/2009 Cross-Browser Widgets
05/08/2009 Monadic parser library for JavaScript
05/05/2009 They Shoot Browsers, Don’t They?
05/01/2009 Feature Detection: State of the Art Browser Scripting


INDUSTRY NEWS
05/19/2006 Ajax grabs center stage at JavaOne, By Tony Baer
05/15/2006 Oracle to boost AJAX, Java , By Paul Krill
05/13/2006 Open AJAX Group Drafts Development Plans, By Stacy Cowley
05/13/2006 AJAX Powers Interactive Marketing ASP, By AjaxWorld News Desk
05/12/2006 AJAX Experts Tackle Security, Other Issues , By Darryl K. Taft
05/11/2006 Adobe Releases Spry Framework for AJAX, By AjaxWorld News Desk
More 
       

      © 2008 ajaximpact.com. All rights reserved.