struts2 and ajax

Struts2 is a very interesting framework for java web application development. It also provide special ajax support in struts2. But there is a problem because you have to use different plugin with different version of struts for the ajax support. And there is a lot of confusion due to this.
like in struts2.0.X you can use dojo plugin for ajax supported but in newer version of struts i.e struts2.2.3 + , jQuery plugin is use to get ajax support.

For struts 2.2.3 + and jQuery example and plugins
refer link:


struts2 and Dojo

A definition form
Dojo is a collection of JavaScript utilities providing solutions for a vast array of problems faced by the professional JavaScript developer. Dojo Base is the foundation of the Dojo Toolkit and functionality such as DOM and AJAX convenience methods, animations, and other base functionality suitable for building simple Web sites. Dojo Core is a larger set of components built upon Dojo Base and includes things such as drag and drop, l10n and i18n components, and data stores. Dijit is a complete widget system, providing all core UI components and utilities, andDojoX is a collection of advanced components, including data grids, low-level graphics libraries, mobile components, and other experimental software. Finally, the Utilities section provides extensive information about theDojo Build systemDojo Module Loader, and a variety of other Dojo-related utilities.

Dojo toolkit is very use for those who  don’t want to work with JavaScript . As I am not good in JavaScript that is why i am seeking for some thing different. then i came to know about Dojo here is the simple example that i have done in struts2 and Dojo by using Dojo plugin. for this your have to first download the dojo plugin and put it in the libraries of your project .

Step-1 Download dojo plugin

Now right click on the libraries in your struts2 project > Add Jar/folder > now give the location of the dojo plugin that you have just downloaded > select dojo plugin > cilck ok.

copy and paste the following files






NOTE – It is recommended that you should use jQuery with Struts2 rather than dojo. Dojo is very rich and make the work easy but the use of Dojo with struts2 will be deprecated .