Java Mailing List Archive

http://www.gg3721.com/

Home » Struts Users Mailing List »

user Digest 20 May 2008 07:42:55 -0000 Issue 8037

user-digest-help

2008-05-20


Author LoginPost Reply

user Digest 20 May 2008 07:42:55 -0000 Issue 8037

Topics (messages 186580 through 186596):

Re: Problems with forms field
 186580 by: Milan Milanovic
 186581 by: Felipe Lorenz
 186594 by: Laurie Harper

Re: Expressions and migration from 2.0.9
 186582 by: Dave Newton
 186583 by: Oleg Mikheev
 186584 by: Musachy Barroso

Jsp struts
 186585 by: Sapan
 186595 by: Antonio Petrelli

Action Form values are null on submit
 186586 by: Shanna7463

Re: [Struts 2] Datetimepicker tag Bug ?!
 186587 by: Milan Milanovic
 186593 by: Ian Meikle

Re: Struts 2 with RAD 6
 186588 by: achandra

Struts 2 with Axis WS NOPS.
 186589 by: Felipe Lorenz
 186590 by: Felipe Lorenz

Re: html:select javascript onchange passing parameter problem
 186591 by: Mahawilai
 186592 by: Sindhu C R

Re: Spring autowiring null values
 186596 by: Ian Meikle

Administrivia:

---------------------------------------------------------------------
To post to the list, e-mail: user@(protected)
To unsubscribe, e-mail: user-digest-unsubscribe@(protected)
For additional commands, e-mail: user-digest-help@(protected)

----------------------------------------------------------------------

Attachment: user_186580.ezm (zipped)
Check the names of the fields, they must mach with attributes names in action class, and also check that you have correct get/set methods for them in your action class.

--
Milan

Jim Kiley <jhkiley@(protected),

It would be much easier for others to help you if you would include relevant
parts of your code, as well as let us know what version of Struts you are
using.

jk

On Mon, May 19, 2008 at 2:15 PM, Felipe Lorenz
wrote:

> Hi,
>
> i did work with struts, and im work with it. But, i dont how, the value of
> field are not send to Action class.. for example:
>
> My forms have 3 fields.. text.. normal.. simple..
>
> so, when i submit this the form only the last filed are set.
>
> I put a System.out in my action class, and i see only the last field
> seted..
> the other stay NULL...
>
> Why?
>



--
Jim Kiley
Technical Consultant | Summa
[p] 412.258.3346 [m] 412.445.1729
http://www.summa-tech.com


   

Attachment: user_186581.ezm (zipped)
Ok.. i did it... its all right.. but i dont know...

i will print my code:

JSP:
<%@(protected)"%>
<%@(protected)" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
 "http://www.w3.org/TR/html4/loose.dtd">
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>JSP Page</title>
  </head>
  <body>
    <s:form action="save_dadosPessoais" method="POST" theme="xhtml">
       <s:textfield name="dadosPessoais.nome" theme="xhtml"/>
       <s:textfield name="dadosPessoais.cpf" theme="xhtml"/>
       <s:textfield name="dadosPessoais.origem" theme="xhtml"/>
       <s:submit value="Enviar" theme="xhtml" />
    </s:form>
  </body>
</html>

MY STRUTS.XML:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE struts PUBLIC
  "-//Apache Software Fundation//DTD Struts Configuration 2.0//EN"
  "./struts-2.0.dtd">
<struts>
  <include file="struts-default.xml" />
  <package name="default" extends="struts-default">
    <action name="save_dadosPessoais" method="create"
class="br.com.mercur.th.action.DadosPessoaisAction">
       <result>/TH_DadosPessoais.jsp</result>
    </action>
  </package>
</struts>

ACTION CLASS
public class DadosPessoaisAction
{
  private DadosPessoais dadosPessoais;
  public String create()
  {
    System.out.println("DADOS PESSOAIS");
    System.out.println(dadosPessoais.getNome());
    System.out.println(dadosPessoais.getOrigem());
    System.out.println(dadosPessoais.getCpf());

    return ActionSupport.SUCCESS;
  }

  public void setDadosPessoais(DadosPessoais dadosPessoais) {
    this.dadosPessoais = dadosPessoais;
  }
}

DadosPessoais Class:
public class DadosPessoais
{
  private String nome;
  private String origem;
  private String cpf;
  public void setNome(String nome) {
    this.nome = nome;
  }
  public String getNome() {
    return nome;
  }
  public void setOrigem(String origem) {
    this.origem = origem;
  }
  public String getOrigem() {
    return origem;
  }
  public String getCpf() {
    return cpf;
  }
  public void setCpf(String cpf) {
    this.cpf = cpf;
  }


}


On Mon, May 19, 2008 at 3:30 PM, Milan Milanovic <milanmilanovich@(protected)>
wrote:

> Check the names of the fields, they must mach with attributes names in
> action class, and also check that you have correct get/set methods for them
> in your action class.
>
> --
> Milan
>
> Jim Kiley <jhkiley@(protected),
>
> It would be much easier for others to help you if you would include
> relevant
> parts of your code, as well as let us know what version of Struts you are
> using.
>
> jk
>
> On Mon, May 19, 2008 at 2:15 PM, Felipe Lorenz
> wrote:
>
> > Hi,
> >
> > i did work with struts, and im work with it. But, i dont how, the value
> of
> > field are not send to Action class.. for example:
> >
> > My forms have 3 fields.. text.. normal.. simple..
> >
> > so, when i submit this the form only the last filed are set.
> >
> > I put a System.out in my action class, and i see only the last field
> > seted..
> > the other stay NULL...
> >
> > Why?
> >
>
>
>
> --
> Jim Kiley
> Technical Consultant | Summa
> [p] 412.258.3346 [m] 412.445.1729
> http://www.summa-tech.com
>
>
>
>

Attachment: user_186594.ezm (zipped)
Looks like you're missing a getter for dadosPessoais in your action class...

L.

Felipe Lorenz wrote:
> Ok.. i did it... its all right.. but i dont know...
>
> i will print my code:
>
> JSP:
> <%@(protected)"%>
> <%@(protected)" %>
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
>   "http://www.w3.org/TR/html4/loose.dtd">
> <html>
>   <head>
>      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
>      <title>JSP Page</title>
>   </head>
>   <body>
>      <s:form action="save_dadosPessoais" method="POST" theme="xhtml">
>         <s:textfield name="dadosPessoais.nome" theme="xhtml"/>
>         <s:textfield name="dadosPessoais.cpf" theme="xhtml"/>
>         <s:textfield name="dadosPessoais.origem" theme="xhtml"/>
>         <s:submit value="Enviar" theme="xhtml" />
>      </s:form>
>   </body>
> </html>
>
> MY STRUTS.XML:
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE struts PUBLIC
>   "-//Apache Software Fundation//DTD Struts Configuration 2.0//EN"
>   "./struts-2.0.dtd">
> <struts>
>   <include file="struts-default.xml" />
>   <package name="default" extends="struts-default">
>      <action name="save_dadosPessoais" method="create"
> class="br.com.mercur.th.action.DadosPessoaisAction">
>         <result>/TH_DadosPessoais.jsp</result>
>      </action>
>   </package>
> </struts>
>
> ACTION CLASS
> public class DadosPessoaisAction
> {
>   private DadosPessoais dadosPessoais;
>   public String create()
>   {
>      System.out.println("DADOS PESSOAIS");
>      System.out.println(dadosPessoais.getNome());
>      System.out.println(dadosPessoais.getOrigem());
>      System.out.println(dadosPessoais.getCpf());
>
>      return ActionSupport.SUCCESS;
>   }
>
>   public void setDadosPessoais(DadosPessoais dadosPessoais) {
>      this.dadosPessoais = dadosPessoais;
>   }
> }
>
> DadosPessoais Class:
> public class DadosPessoais
> {
>   private String nome;
>   private String origem;
>   private String cpf;
>   public void setNome(String nome) {
>      this.nome = nome;
>   }
>   public String getNome() {
>      return nome;
>   }
>   public void setOrigem(String origem) {
>      this.origem = origem;
>   }
>   public String getOrigem() {
>      return origem;
>   }
>   public String getCpf() {
>      return cpf;
>   }
>   public void setCpf(String cpf) {
>      this.cpf = cpf;
>   }
>
>
> }
>
>
> On Mon, May 19, 2008 at 3:30 PM, Milan Milanovic <milanmilanovich@(protected)>
> wrote:
>
>> Check the names of the fields, they must mach with attributes names in
>> action class, and also check that you have correct get/set methods for them
>> in your action class.
>>
>> --
>> Milan
>>
>> Jim Kiley <jhkiley@(protected),
>>
>> It would be much easier for others to help you if you would include
>> relevant
>> parts of your code, as well as let us know what version of Struts you are
>> using.
>>
>> jk
>>
>> On Mon, May 19, 2008 at 2:15 PM, Felipe Lorenz
>> wrote:
>>
>>> Hi,
>>>
>>> i did work with struts, and im work with it. But, i dont how, the value
>> of
>>> field are not send to Action class.. for example:
>>>
>>> My forms have 3 fields.. text.. normal.. simple..
>>>
>>> so, when i submit this the form only the last filed are set.
>>>
>>> I put a System.out in my action class, and i see only the last field
>>> seted..
>>> the other stay NULL...
>>>
>>> Why?
>>>
>>
>>
>> --
>> Jim Kiley
>> Technical Consultant | Summa
>> [p] 412.258.3346 [m] 412.445.1729
>> http://www.summa-tech.com
>>
>>
>>
>>
>


Attachment: user_186582.ezm (zipped)
Change the TLD?

The combination of the two levels of EL is a security risk in some
applications. If you're not worried about it or not affected by it then
it's an easy, if annoying, workaround.

Dave

--- Oleg Mikheev <mihel@(protected):

> I was trying to upgrade from 2.0.9 to the latest Struts 2 and
> encountered this issue:
> http://issues.apache.org/struts/browse/WW-2107
>
> If I have a lot of code like this:
>
> <s:checkbox
> id="${transactionType}form_qoInceptionPPDO_${forStatus.index}"
>
> name="qoInceptionPPDO_${forStatus.index}" theme="simple"
>
> fieldValue="${requestScope[tmpVar]}" value="${not empty renewaledId ?
>
> false : requestScope[tmpVar]}"
>                                   onclick="${not
> empty
> renewaledId ? 'return false' : ''}"
>
>
onchange="document.getElementById('${transactionType}form_qoInceptionPPDO_${forStatus.index}').value=document.getElementById('${transactionType}form_qoInceptionPPDO_${forStatus.index}').checked"/>
>
> is there any 'easy' way of making it work with the latest Struts2?
> If there is no easy way I will continue using Struts 2.0.9 since
> trying
> to port that stuff will become a nightmare.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>
>


Attachment: user_186583.ezm (zipped)
Dave Newton wrote:
> Change the TLD?
>
> The combination of the two levels of EL is a security risk in some
> applications. If you're not worried about it or not affected by it then
> it's an easy, if annoying, workaround.

Thanks
Is repackaging struts jar the only way of doing that?


Attachment: user_186584.ezm (zipped)
You can define a taglib-location in web.xml, but I am not sure if that
overwrites the one from the jar file.

musachy

On Mon, May 19, 2008 at 3:14 PM, Oleg Mikheev <mihel@(protected):
> Dave Newton wrote:
>>
>> Change the TLD?
>>
>> The combination of the two levels of EL is a security risk in some
>> applications. If you're not worried about it or not affected by it then
>> it's an easy, if annoying, workaround.
>
> Thanks
> Is repackaging struts jar the only way of doing that?
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>
>



--
"Hey you! Would you help me to carry the stone?" Pink Floyd

Attachment: user_186585.ezm (zipped)

Hi ,


Hi,
I got
???en_US.errors.required??????en_US.errors.required???  this error on my
entry form before submit any button andd I used <input
type="button" value="Submit As Draft" onclick="return validateKForm(this)">
at end of form
i want to show my message on message or dialog box I donot know where it
goes wrong

my code is as follows

struts-config.xml

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE struts-config PUBLIC "-//Apache Software Foundation//DTD Struts
Configuration 1.1//EN"
"http://jakarta.apache.org/struts/dtds/struts-config_1_1.dtd">
<struts-config>
 <!-- =========================== DynaActionForms ==========================
-->
 <form-beans>
   <form-bean name="kForm"
type="org.apache.struts.validator.DynaValidatorForm" >
     <form-property name="ID" type="java.lang.Integer"/>
     <form-property name="kDescription" type="java.lang.String"/>
     <form-property name="title" type="java.lang.String"/>
       </form-bean>
 </form-beans>
 
 
 <action-mappings type="org.apache.struts.action.ActionMapping">

        <action name="kForm"
               path="/kAdd"
               type="com.riskMngmnt.presentation.k.KDispatchAction"
               scope="request"
               validate="true"
               input="k.add">
        <forward name="add" path="k.add"/>
        <forward name="view" path="k.view"/>
        </action>
       
           

  <message-resources parameter="/WEB-INF/MessageResourcesK.properties"
null="false"/>
     
<!-- Validator plugin -->
<plug-in className="org.apache.struts.validator.ValidatorPlugIn">
<set-property property="pathnames"
     
value="/WEB-INF/validator-k-rules.xml,/WEB-INF/validation-k.xml"/>
     
</plug-in>        

</struts-config>


My messageresource.properties


# Error messages for Validator framework validations
#-- validation errors
errors.invalid={0} is invalid.
errors.maxlength={0} can not be greater than {1} characters.
errors.minlength={0} can not be less than {1} characters.
errors.range={0} is not in the range {1} through {2}.
errors.required={0} is required.
errors.byte={0} must be an byte.
errors.date={0} is not a date.
errors.double={0} must be an double.
errors.float={0} must be an float.
errors.integer={0} must be an integer.
errors.long={0} must be an long.
errors.short={0} must be an short.
errors.creditcard={0} is not a valid credit card number.
errors.email={0} is an invalid e-mail address.

#--diplay names
prompt.title = Title
prompt.kDescription = KDescription


validation-k.xml

<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE form-validation
PUBLIC "-//Apache Software Foundation//DTD Commons Validator Rules
Configuration 1.1.3//EN"
      "http://jakarta.apache.org/commons/dtds/validator_1_1_3.dtd">


<form-validation>
 <formset>
   <form name="kForm">
       
        <field property="title"
             depends="required">
        <arg0  key="prompt.title" />
        </field>
   
        <field property="kDescription" depends="required">
        <arg0 key="prompt.kDescription" ></arg0>
         </field>
         
   </form>
 </formset>
</form-validation>


my KForm.java


import javax.servlet.http.HttpServletRequest;

import org.apache.struts.action.ActionErrors;

import org.apache.struts.action.ActionMapping;
import org.apache.struts.action.ActionMessage;
import org.apache.struts.validator.ValidatorForm;


public class KForm extends ValidatorForm {

private String title;
private String kDescription;

public void setTitle(String title)
{
  this.title=title;
}

public String getTitle()
{
  return title;
}
....
.
.
..

public void reset(ActionMapping mapping, HttpServletRequest request) {
 
      this.title=null;
   this.kDescription=null;
    }

    /**
    * Reset all properties to their default values.
    *
    * @param mapping The mapping used to select this instance
    * @param request The servlet request we are processing
   * @return errors
    */
  public ActionErrors validate(ActionMapping mapping, HttpServletRequest
request )
  {
   
   
   
    System.out.println("validate in in kForm.java");
     ActionErrors errors = new ActionErrors();
     
     System.out.println("k form validate method");

     if( getTitle() == null || getTitle().length() < 1 )
     {
            errors.add("title",new ActionMessage("errors.required"));
     }

    if( getKDescription() == null || getKDescription().length() < 1 )
    {
      errors.add("kDescription",new ActionMessage("errors.required"));
    }
     return errors;
  }

 }


in main jsp

<html:html locale="true">
<body>
  <form action="<%=path %>/k.do?method=save" method="post" name="kForm" >
----
<p>
<html:errors/>
</p>
<input type="button" value="Submit As Draft" onclick="return
validateKriForm(this);"/><br></td>
           <td valign="top">





--
Sent from the Struts - User mailing list archive at Nabble.com.


Attachment: user_186595.ezm (zipped)
2008/5/19 Sapan <swapna.khedkar@(protected)>:
> ???en_US.errors.required??????en_US.errors.required???

Usually this happens when you are using the <fmt:message> tag: it does
not find a property with that name, in this case
"en_US.errors.required", or possibly "errors.required" with "en_US"
locale.
Check your message bundles, the configuration and the correctness of
your JSP page.

Antonio

Attachment: user_186586.ezm (zipped)

I have a web application using struts and it works fine with IE 7, however in
IE 6 I am getting null for all of the form values. Do I need to use a older
version of struts or am I doing something in my JSP that is clearing the
table?

Here is my JSP:

<%@(protected)"
import="java.sql.*" errorPage="" %>
<%--
The taglib directive below imports the JSTL library. If you uncomment it,
you must also add the JSTL library to the project. The Add Library... action
on Libraries node in Projects view can be used to add the JSTL 1.1 library.
--%>
<%--
<%@(protected)"%>
--%>

<%@(protected)" %>
<%@(protected)" %>
<%@(protected)" %>

<%@(protected)" %>
<%@(protected)" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <link rel="stylesheet"
href="<%=request.getContextPath()%>/stylesheets/application.css"
type="text/css">
    <title>HARPS User Management</title>
    <script language="javascript" src="roleMethods.js">              
    </script>
   
    <tab:tabConfig />
  </head>
 
  <body>
    <%-- Checks that the user has Admin Privileges (incase they are
trying to access the page directly through the URL) --%>
    <%-- COMMENT OUT FOR NON-JOSSO VERSION
    <%
if(!CheckAccess.CheckAccessControl(request.getUserPrincipal().getName(), 1))
{
       response.sendRedirect(request.getContextPath() +
"/authorizationError.jsp");
       }
    %>
      END NON-JOSSO COMMENTING --%>

  <tab:tabContainer id="role-management">
    <tab:tabPane id="roleAssignment" tabTitle="Assign Roles">
       <h1> Add Users to a Role </h1>
       
       <table width="100%" cellpadding="0" cellspacing="0">
          <tr>
            <td align="center"><html:errors/></td>
          </tr>
       </table>
       
       <html:form action="/LoadUsers.do" target="mainFrameportal">
          <html:hidden name="command" property="command"
value="initial"/>          
         
          <table>
            <tr>
               <td>Roles:</td>
               <td>Current Users in Role:</td>
               <td>All HARPS Users:</td>
            </tr>
            <tr>
               <td>
                  <html:select property="rolesList_id"
multiple="false" size="10" onclick="submit()">
                    <html:options collection="roleList"
property="value" labelProperty="label"/>
                  </html:select>
               </td>
               <td>
                  <html:select property="userRoleList_id"
multiple="true" size="10">
                    <html:options collection="userRoleList"
property="value" labelProperty="label"/>
                  </html:select>
               </td>
               <td>        
                  <html:select property="userList_id"
multiple="true" size="10">
                    <html:options collection="userList"
property="value" labelProperty="label"/>
                  </html:select>
               </td>
            </tr>
            <tr>
               <td></td>
               <td></td>
               <td></td>
            </tr>
            <tr>
               <td></td>
               <td><html:checkbox
property="emailOption"/><bean:message key="email.option"/></td>
               <td></td>
            </tr>
            <tr>
               <td></td>
               <td></td>
               <td></td>
            </tr>
            <tr>
               <td slign="center"><html:button
property="removeRole" value="Remove Role" onclick="if(confirmAction())
{command.value='removeRole';submit()}"/></td>
               <td align="center"><html:button
property="removeUser" value="Remove User >>"
onclick="command.value='remove';submit()"/></td>
               <td align="center"><html:button property="addUser"
value="<< Add User" onclick="command.value='addUser';submit()"/></td>
            </tr>
          </table>
        </html:form>
    </tab:tabPane> ...

Thank you for any suggestions!! %-|

-- Shanna --
--
Sent from the Struts - User mailing list archive at Nabble.com.


Attachment: user_186587.ezm (zipped)
I tried everything with <datetimepicker> tag!

It seems that Struts 2 in 2.0.11.1 version have a bug with type conversion from <s:datetimepicker> jsp tag (that is actually a String) to corresponding java.util.Date field in action class. Could someone confirm this ?

--
Thx, Milan

Milan Milanovic <milanmilanovich@(protected)' ?
 
--
Thx, Milan

Milan Milanovic wrote:
And when I add "value" attribute to this tag like this:

format="#yyyy-#MM-#dd" name="delivery.date" />

it generates and exception:

18:24:22,531 ERROR org.apache.struts2.components.DateTimePicker:316 - Could not parse date
java.text.ParseException: Unparseable date: "pregled.odPeriod"
at java.text.DateFormat.parse(Unknown Source)
at org.apache.struts2.components.DateTimePicker.format (DateTimePicker.java:309)
at org.apache.struts2.components.DateTimePicker.evaluateParams (DateTimePicker.java:202)
at org.apache.struts2.components.UIBean.end (UIBean.java:481)
at org.apache.struts2.views.jsp.ComponentTagSupport.doEndTag (ComponentTagSupport.java:43)
...


Milan Milanovic wrote:
It seems that there is a bug with tag. I defined it as in documentation:



I have delivery object in my action class with date field (of type java.util.Date) and all necessary get/set methods. But when I submit the form I get this error:

17:55:47,968 ERROR com.opensymphony.xwork2.interceptor.ParametersInterceptor:204 - ParametersInterceptor - [setParameters]: Unexpected Exception caught setting 'delivery.date' on 'class com.myProject.actions.MyTestAction: Error setting expression 'delivery.date' with value '[Ljava.lang.String;@(protected)'

It seems that Struts 2 always send String for any type of tag and that it cannot set Date ?

--
Thx in advance, Milan





   

   

Attachment: user_186593.ezm (zipped)
I have had the same problem.
I assume you are not using an US locale in your client browser.
We use Norwegian and German and it does not work.

Regards
Ian

CSC Solutions Norge AS
Registered Office: Sandsliåsen 57, 5254 Sandsli, Norway
Registered in Norway No: 958 958 455

-------------------------------------------------------------------------------------------------------------------------------------------------------------------------
This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery.
NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
any order or other contract unless pursuant to explicit written agreement
or government initiative expressly permitting the use of e-mail for such
purpose.
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------




Milan Milanovic <milanmilanovich@(protected)>
19.05.2008 23:38
Please respond to
"Struts Users Mailing List" <user@(protected)>


To
Struts Users Mailing List <user@(protected)>
cc

Subject
Re: [Struts 2] Datetimepicker tag Bug ?!






I tried everything with <datetimepicker> tag!

It seems that Struts 2 in 2.0.11.1 version have a bug with type conversion
from <s:datetimepicker> jsp tag (that is actually a String) to
corresponding java.util.Date field in action class. Could someone confirm
this ?

--
Thx, Milan

Milan Milanovic <milanmilanovich@(protected)
name="delivery.date" attribute it reads the date good, but it can't store
it back! It generates this error below 'ParametersInterceptor' ?

--
Thx, Milan

Milan Milanovic wrote:
And when I add "value" attribute to this tag like this:

format="#yyyy-#MM-#dd" name="delivery.date" />

it generates and exception:

18:24:22,531 ERROR org.apache.struts2.components.DateTimePicker:316 -
Could not parse date
java.text.ParseException: Unparseable date: "pregled.odPeriod"
at java.text.DateFormat.parse(Unknown Source)
at
org.apache.struts2.components.DateTimePicker.format (DateTimePicker.java:309)
at
org.apache.struts2.components.DateTimePicker.evaluateParams (DateTimePicker.java:202)
at org.apache.struts2.components.UIBean.end (UIBean.java:481)
at
org.apache.struts2.views.jsp.ComponentTagSupport.doEndTag (ComponentTagSupport.java:43)
...


Milan Milanovic wrote:
It seems that there is a bug with tag. I defined it as in documentation:



I have delivery object in my action class with date field (of type
java.util.Date) and all necessary get/set methods. But when I submit the
form I get this error:

17:55:47,968 ERROR
com.opensymphony.xwork2.interceptor.ParametersInterceptor:204 -
ParametersInterceptor - [setParameters]: Unexpected Exception caught
setting 'delivery.date' on 'class com.myProject.actions.MyTestAction:
Error setting expression 'delivery.date' with value
'[Ljava.lang.String;@(protected)'

It seems that Struts 2 always send String for any type of tag and that it
cannot set Date ?

--
Thx in advance, Milan









Attachment: user_186588.ezm (zipped)

Hello Cheng,
 I am trying to make Struts 2 work with RAD 7.0. It is not working I mean
the very first page is fine but after that when it tries to look for the
action, it is giving error and in the url it is ending .action. It is not
able to find the jsp page. I can send the directory structure and struts.xml
and the folder where I am putting struts.xml and jsp pages. I am missing
something or placing things in wrong directories. I am very close and I
guess there is small change that can make it work.
Thank you

Cheng Wei Lee wrote:
>
> I've no difficulties using Struts 2 on RAD v7. What are you actually
> trying
> to do? To build Struts 2 from scratch?
>
> On Jan 17, 2008 9:42 PM, <Rushabh_Raval@(protected):
>
>> Hi,
>>
>> I am trying to figure out how could I use Strus-2 with RAD-6 which has
>> Jdk
>> 1.4.
>>
>> I even tried to run the mail reader application on RAD -7 which has jdk
>> 1.5 with JRE 5.
>>
>> Could someone please help me running the sample code on RAD-6. I was also
>> not able to figure out how I could use jdk 1.5 on RAD-6.
>>
>> I am aware that there is a build for jdk1.4 but does it have some
>> functional or performance difference from the Struts-2 build for jdk 1.5
>>
>> I am getting an exception
>>
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R
>> java.lang.LinkageError: LinkageError while defining class:
>> org.apache.struts2.dispatcher.FilterDispatcher
>> Could not be defined due to:
>> org/apache/struts2/dispatcher/FilterDispatcher (Unsupported major.minor
>> version 49.0)
>> This is often caused by having a class defined at multiple
>> locations within the classloader hierarchy. Other potential causes
>> include compiling against an older or newer version of the class
>> that has an incompatible method signature.
>> Dumping the current context classloader hierarchy:
>>   ==> indicates defining classloader
>>  [0] com.ibm.ws.bootstrap.ExtClassLoader@(protected)
>>  [1] sun.misc.Launcher$AppClassLoader@(protected)
>>  [2] sun.misc.Launcher$ExtClassLoader@(protected)
>> ---Original exception---
>> java.lang.UnsupportedClassVersionError:
>> org/apache/struts2/dispatcher/FilterDispatcher (Unsupported major.minor
>> version 49.0)
>>     at java.lang.ClassLoader.defineClass0(Native Method)
>>     at java.lang.ClassLoader.defineClass (ClassLoader.java(Compiled
>> Code))
>>     at
>> java.security.SecureClassLoader.defineClass(SecureClassLoader.java
>> (Compiled
>> Code))
>>     at
>> com.ibm.ws.classloader.CompoundClassLoader._defineClass(
>> CompoundClassLoader.java:576)
>>     at
>> com.ibm.ws.classloader.CompoundClassLoader.findClass(
>> CompoundClassLoader.java(Compiled
>> Code))
>>     at
>> com.ibm.ws.classloader.CompoundClassLoader.loadClass(
>> CompoundClassLoader.java(Compiled
>> Code))
>>     at java.lang.ClassLoader.loadClass (ClassLoader.java(Compiled
>> Code))
>>     at java.beans.Beans.instantiate (Beans.java:202)
>>     at java.beans.Beans.instantiate (Beans.java:63)
>>     at
>> com.ibm.ws.webcontainer.filter.WebAppFilterManager.loadFilter(
>> WebAppFilterManager.java:289)
>>     at
>>
>> com.ibm.ws.webcontainer.filter.WebAppFilterManager.getFilterInstanceWrapper
>> (WebAppFilterManager.java:155)
>>     at
>> com.ibm.ws.webcontainer.filter.WebAppFilterManager.getFilterChain(
>> WebAppFilterManager.java:202)
>>     at
>> com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.invokeFilters(
>> DefaultExtensionProcessor.java:536)
>>     at
>> com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.handleRequest(
>> DefaultExtensionProcessor.java:500)
>>     at
>> com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:2837)
>>     at
>> com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:220)
>>     at
>> com.ibm.ws.webcontainer.VirtualHost.handleRequest(VirtualHost.java:204)
>>     at
>> com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:1681)
>>     at
>> com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:77)
>>     at
>> com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(
>> HttpInboundLink.java:421)
>>     at
>> com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(
>> HttpInboundLink.java:367)
>>     at
>> com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(
>> HttpICLReadCallback.java:94)
>>     at
>> com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(
>> WorkQueueManager.java:548)
>>     at
>> com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(
>> WorkQueueManager.java:601)
>>     at
>> com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun(
>> WorkQueueManager.java:934)
>>     at
>> com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(
>> WorkQueueManager.java:1021)
>>     at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1332)
>>
>> --- end Original exception----
>>
>>     at
>> com.ibm.ws.classloader.CompoundClassLoader._defineClass(
>> CompoundClassLoader.java:621)
>>     at
>> com.ibm.ws.classloader.CompoundClassLoader.findClass(
>> CompoundClassLoader.java(Compiled
>> Code))
>>     at
>> com.ibm.ws.classloader.CompoundClassLoader.loadClass(
>> CompoundClassLoader.java(Compiled
>> Code))
>>     at java.lang.ClassLoader.loadClass (ClassLoader.java(Compiled
>> Code))
>>     at java.beans.Beans.instantiate (Beans.java:202)
>>     at java.beans.Beans.instantiate (Beans.java:63)
>>     at
>> com.ibm.ws.webcontainer.filter.WebAppFilterManager.loadFilter(
>> WebAppFilterManager.java:289)
>>     at
>>
>> com.ibm.ws.webcontainer.filter.WebAppFilterManager.getFilterInstanceWrapper
>> (WebAppFilterManager.java:155)
>>     at
>> com.ibm.ws.webcontainer.filter.WebAppFilterManager.getFilterChain(
>> WebAppFilterManager.java:202)
>>     at
>> com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.invokeFilters(
>> DefaultExtensionProcessor.java:536)
>>     at
>> com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.handleRequest(
>> DefaultExtensionProcessor.java:500)
>>     at
>> com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:2837)
>>     at
>> com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:220)
>>     at
>> com.ibm.ws.webcontainer.VirtualHost.handleRequest(VirtualHost.java:204)
>>     at
>> com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:1681)
>>     at
>> com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:77)
>>     at
>> com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(
>> HttpInboundLink.java:421)
>>     at
>> com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(
>> HttpInboundLink.java:367)
>>     at
>> com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(
>> HttpICLReadCallback.java:94)
>>     at
>> com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(
>> WorkQueueManager.java:548)
>>     at
>> com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(
>> WorkQueueManager.java:601)
>>     at
>> com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun(
>> WorkQueueManager.java:934)
>>     at
>> com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(
>> WorkQueueManager.java:1021)
>>     at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1332)
>>
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.classloader.CompoundClassLoader._defineClass(
>> CompoundClassLoader.java:621)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.classloader.CompoundClassLoader.findClass(
>> CompoundClassLoader.java(Compiled
>> Code))
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.classloader.CompoundClassLoader.loadClass(
>> CompoundClassLoader.java(Compiled
>> Code))
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> java.lang.ClassLoader.loadClass (ClassLoader.java(Compiled Code))
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> java.beans.Beans.instantiate (Beans.java:202)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> java.beans.Beans.instantiate (Beans.java:63)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.webcontainer.filter.WebAppFilterManager.loadFilter(
>> WebAppFilterManager.java:289)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>>
>> com.ibm.ws.webcontainer.filter.WebAppFilterManager.getFilterInstanceWrapper
>> (WebAppFilterManager.java:155)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.webcontainer.filter.WebAppFilterManager.getFilterChain(
>> WebAppFilterManager.java:202)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.invokeFilters(
>> DefaultExtensionProcessor.java:536)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.handleRequest(
>> DefaultExtensionProcessor.java:500)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:2837)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:220)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.webcontainer.VirtualHost.handleRequest(VirtualHost.java:204)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:1681)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:77)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(
>> HttpInboundLink.java:421)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(
>> HttpInboundLink.java:367)
>> [1/16/08 18:14:21:842 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(
>> HttpICLReadCallback.java:94)
>> [1/16/08 18:14:21:858 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(
>> WorkQueueManager.java:548)
>> [1/16/08 18:14:21:858 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(
>> WorkQueueManager.java:601)
>> [1/16/08 18:14:21:858 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun(
>> WorkQueueManager.java:934)
>> [1/16/08 18:14:21:858 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(
>> WorkQueueManager.java:1021)
>> [1/16/08 18:14:21:858 IST] 0000003d SystemErr   R   at
>> com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1332)
>>
>> Thanks & Regards,
>> Rushabh Raval
>> +=========================================================+
>> This message may contain confidential and/or privileged
>> information. If you are not the addressee or authorized to
>> receive this for the addressee, you must not use, copy,
>> disclose or take any action based on this message or any
>> information herein. If you have received this message in
>> error, please advise the sender immediately by reply e-mail
>> and delete this message. Thank you for your cooperation.
>> +=========================================================+
>>
>
>

--
Sent from the Struts - User mailing list archive at Nabble.com.


Attachment: user_186589.ezm (zipped)
Hi dudes.

I have a problem.

Ive try to acess a Web Service, created with Axis 1.4, with my struts
aplication. But it throw a java.net.ConnectException: Connection timed out:
connect.

but, when i execute my class to test the acess of WS without tomcat, etc...,
its works.

What can be?

My libraries:
- axis.jar
- jaxrpc.jar
- commons-discovery-0.2.jar
- activation.jar
- saaj.jar
- wsdl4j-1.5.1.jar

..and Struts 2.0.11.1

Tnks!

Attachment: user_186590.ezm (zipped)
UPDATE:

i've did try with Tomcat 5.5 and 6, but still not working.

On Mon, May 19, 2008 at 8:25 PM, Felipe Lorenz <felipe.lorenz@(protected)>
wrote:

> Hi dudes.
>
> I have a problem.
>
> Ive try to acess a Web Service, created with Axis 1.4, with my struts
> aplication. But it throw a java.net.ConnectException: Connection timed out:
> connect.
>
> but, when i execute my class to test the acess of WS without tomcat,
> etc..., its works.
>
> What can be?
>
> My libraries:
>  - axis.jar
>  - jaxrpc.jar
>  - commons-discovery-0.2.jar
>  - activation.jar
>  - saaj.jar
>  - wsdl4j-1.5.1.jar
>
> ..and Struts 2.0.11.1
>
> Tnks!
>

Attachment: user_186591.ezm (zipped)

I have the same problem, Please tell me how to fix it if you know how.

thank you very much

Mahawilai


Benz wrote:
>
> this is my part of jsp:
> ....
> <logic:iterate id="loop" indexId="idx" name="data">
> ....
>  <html:select name="loop" property="sts_1" onchange="checkStsCombo(this,
> 'hasil_1', '<%=idx%>');">
>  ...
>  </html:select>
> ...
> </logic:iterate>
> ...
>
> I get the html result:
> ...
>  <select name="sts_1" onchange="checkStsCombo(this, 'hasil_1',
> '<%=idx%>');">
> ...
>
> The '<%=idx%>' text in jsp should be rendered as the value of idx valu
> which is such as '0','1',etc.
> Can anybody tell me why it doesn't works?
>
> Best Regards,
>
> Benz
>

--
Sent from the Struts - User mailing list archive at Nabble.com.


Attachment: user_186592.ezm (zipped)
I cld nt still fix it..
Let me no if u cld proceed.



Regards,
Sindhu C.R

 Please don't print this Email unless you really need to - this will preserve trees on planet earth.
===========================================================================================

-----Original Message-----
From: Mahawilai [mailto:orn_orn_@(protected)]
Sent: Tuesday, May 20, 2008 9:26 AM
To: user@(protected)
Subject: Re: html:select javascript onchange passing parameter problem


I have the same problem, Please tell me how to fix it if you know how.

thank you very much

Mahawilai


Benz wrote:
>
> this is my part of jsp:
> ....
> <logic:iterate id="loop" indexId="idx" name="data">
> ....
>  <html:select name="loop" property="sts_1" onchange="checkStsCombo(this,
> 'hasil_1', '<%=idx%>');">
>  ...
>  </html:select>
> ...
> </logic:iterate>
> ...
>
> I get the html result:
> ...
>  <select name="sts_1" onchange="checkStsCombo(this, 'hasil_1',
> '<%=idx%>');">
> ...
>
> The '<%=idx%>' text in jsp should be rendered as the value of idx valu
> which is such as '0','1',etc.
> Can anybody tell me why it doesn't works?
>
> Best Regards,
>
> Benz
>

--
Sent from the Struts - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@(protected)
For additional commands, e-mail: user-help@(protected)


No virus found in this incoming message.
Checked by AVG.
Version: 8.0.100 / Virus Database: 269.23.21/1455 - Release Date: 5/19/2008 5:04 PM


Attachment: user_186596.ezm (zipped)
Hi Dave,

Thanks for that, I have now read the Spring documentation.
It seems that the default in Spring is no autowiring so no further config
required here.

It seems that it is the STRUTS2 Spring plugin that needs to be configured
to not perform autowiring, specifically
com.opensymphony.xwork2.spring.SpringObjectFactory
which is a part of xwork2.

Looking at the source code it does not seem that autowiring can be
switched off and this I feel is a problem.

Regards
Ian

CSC Solutions Norge AS
Registered Office: Sandsliåsen 57, 5254 Sandsli, Norway
Registered in Norway No: 958 958 455

-------------------------------------------------------------------------------------------------------------------------------------------------------------------------
This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery.
NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
any order or other contract unless pursuant to explicit written agreement
or government initiative expressly permitting the use of e-mail for such
purpose.
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------




Dave Newton <newton.dave@(protected)>
19.05.2008 17:16
Please respond to
"Struts Users Mailing List" <user@(protected)>


To
Struts Users Mailing List <user@(protected)>
cc

Subject
Re: Spring autowiring null values






--- Ian Meikle <imeikle@(protected):

> I have already read this page, the possible values are given as:
>
> name, type, auto or constructor.
>
> There is no NONE, or OFF value, and looking at the source code there
> does not seem to be support for it either.
> Hence why I am asking if there is another way of turning this off.

That's why I mentioned the Spring documentation.

http://static.springframework.org/spring/docs/2.0.x/reference/beans.html#beans-factory-autowire


Unless you're using 2.5, in which case look in the 2.5 documentation.

Dave


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@(protected)
For additional commands, e-mail: user-help@(protected)


©2008 gg3721.com - Jax Systems, LLC, U.S.A.