top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

struts 2 ajax choice

0 votes
587 views

from the document,

Struts 2 support both DoJo plugin and JSON plugin,
which one is easy to plugin and use?
which one is more powerful?

posted May 14, 2013 by anonymous

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

4 Answers

+1 vote

Please note the Dojo plugin is deprecated.

answer May 14, 2013 by anonymous
0 votes

Will the S2 jQuery plugin provide the similar functions as S2 dojo plugin?
Is S2 jQuery plugin maintained by Struts 2 team? I am using Dojo plugin
right now, and it works pretty well. Could anyone give me explanation why
S2 Dojo plugin get deprecated?

answer May 14, 2013 by anonymous
0 votes

The docs and examples are available on the site I linked to.

The S2 jQuery plugin I linked to is an independent project that happens to have at least one S2 team member on it.

It is *not* an official plugin, but it's quite a bit more recent, and better (IMO) than the deprecated Dojo plugin.

answer May 14, 2013 by anonymous
0 votes

They're not even close to being the same thing.
The JSON plugin provides JSON de/serialization. The Dojo plugin was a complete client-side tag library.
There's the S2 jQuery plugin http://code.google.com/p/struts2-jquery/ which would be the non-official equivalent of the old Dojo taglib.

answer May 14, 2013 by Salil Agrawal
Similar Questions
+1 vote

I have a problem/doubt and describing here.I am using struts1.1(no plain jsp's only struts tags) and needs to implement ajax in that.Q-1) With out giving "action" property can't we write ?. If no I am using ajax in that
form(now my form having button to submit form data). Could any one please help how to add my response back to form variable in same page.

Login Success

my action class is

package app;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.struts.action.Action;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;

public class DetailsAction extends Action {    
 public ActionForward execute (ActionMapping mapping, ActionForm  form, HttpServletRequest request,HttpServletResponse  response) throws Exception    
 {
 RegisterForm detailsForm = (RegisterForm)form;
 detailsForm.setUsername("Struts");
 System.out.println("inr"+detailsForm.getUsername());
 return mapping.findForward("success");
 }    
} 
+2 votes

I have a couple of old struts 2 apps that are using 2.2.1. I want to upgrade them to 2.3. What is the minimal set of jar files I need in WEB-INF/lib?

I currently have:
commons-beanutils-1.7.jar
commons-collections-2.1.jar
commons-digester-1.7.jar
commons-fileupload-1.2.1.jar
commons-io-1.4.jar
commons-javaflow-20060411.jar
commons-lang-2.5.jar
commons-logging-1.0.4.jar
freemarker-2.3.16.jar
ibatis-2.3.2.715.jar
itext-1.3.1.jar
jasperreports-2.0.5.jar
javamail.jar
javassist-3.8.0.GA.jar
jdt-compiler-3.1.1.jar
jstl.jar
jxl-2.6.jar
log4j-1.2.14.jar
ognl-3.0.jar
poi-3.0.1-FINAL-20070705.jar
spring.jar
standard.jar
struts2-core-2.2.1.jar
struts2-jasperreports-plugin-2.0.11.1.jar
urlrewrite-3.2.0.jar
xalan.jar
xercesImpl.jar
xwork-core-2.2.1.jar

+1 vote

I am in the process of upgrading my struts2.3.1.2 application to struts2.3.15.1. Everything works fine except the and tags. In struts2.3.1.2, I have the following code in jsp file

  %{stateName}
  Add 

I used to get correct state name when using struts2.3.1.2. However, using struts2.3.15.1, I am getting the following on web-browser page: %{stateName}

+1 vote

I am using struts 2.2.3 and doing client side validation using xml. I want to do validation for a field whose name is an ognl expression I have something like this :

Field is required

On debugging I can see It is adding field error properly. But i have a javascript which shows the field in red highlighted color and also shows messages that "fieldname is required". However fieldname is not coming in the message and it is not showing the required field in red highlighted color.

The same javascript code works fine for normal fields which have static name. Please can someone help in this, as I am new to struts ?

...