Java Mailing List Archive

http://www.gg3721.com/

Home » Struts Users Mailing List »

user Digest 2 Jun 2008 14:30:47 -0000 Issue 8065

user-digest-help

2008-06-02


Author LoginPost Reply

user Digest 2 Jun 2008 14:30:47 -0000 Issue 8065

Topics (messages 187090 through 187117):

Re: Are sessions confused?
 187090 by: Martin
 187091 by: Juan Pablo Pizarro
 187100 by: Al Sutton
 187109 by: Juan Pablo Pizarro

Re: Session Data overlap?
 187092 by: McDowell, Paula

[OT] RE: Session Data overlap?
 187093 by: Dave Newton
 187095 by: McDowell, Paula
 187097 by: jbostjr

Re: Action-Redirect Parameter Problem
 187094 by: Adam Hardy
 187106 by: Mark Lester
 187108 by: Adam Hardy

Struts2 can't populate array property to form beans
 187096 by: Jacky Shih
 187099 by: l4kyl4ky.gmail.com
 187117 by: Jacky Shih

Event Handler API
 187098 by: Jay Bose

Struts 2 / Eclipse
 187101 by: Andrew Myers
 187105 by: Dave Newton
 187107 by: Martin
 187110 by: kindlerm.arcor.de
 187111 by: Musachy Barroso

Re: Struts2 onchange event should do the same like submit(with ajax tag). How ?
 187102 by: zeermi

chaining actions
 187103 by: balaji.m.cs

Re: i18nInterceptor in Linux
 187104 by: Regalut

Re: [Struts 2] Set action parameter - simple
 187112 by: Milan Milanovic
 187113 by: Musachy Barroso
 187114 by: Milan Milanovic
 187115 by: Musachy Barroso
 187116 by: Milan Milanovic

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_187090.ezm (zipped)
can you display the session_id from your test scenarios?

Thanks
----- Original Message -----
From: "Juan Pablo Pizarro" <juanpablo.pizarro@(protected)>
To: "Struts Users Mailing List" <user@(protected)>
Sent: Sunday, June 01, 2008 11:30 AM
Subject: Re: Are sessions confused?


> Yes I know, but my application was struts2-blank-2.0.11.1.war (from
> struts-2.0.11.1-all.zip). Then I coded a bit and I posted that.
>
> JP
>
> 2008/6/1 Dave Newton <newton.dave@(protected)>:
>> --- On Fri, 5/30/08, Juan Pablo Pizarro wrote:
>>> With ServletActionContext.getRequest().getSession().setAttribute("user",
>>> (int) (Math.random() * 100)); the problem is only in
>>> firefox!!.
>>
>> If you're on different machines and seeing the wrong session data on them
>> then something is broken with your application. I've never seen this in
>> S2 and as said before most of us here are using S2 sessions without any
>> issues.
>>
>> Dave
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscribe@(protected)
>> For additional commands, e-mail: user-help@(protected)
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>
>


Attachment: user_187091.ezm (zipped)
Yes, the effect is the same.. :( everything is ok, but when I pressed
ctrl+f5, the sessions are the last again.

How you put thing in the session from a action?

2008/6/1, Martin <mgainty@(protected)>:
> can you display the session_id from your test scenarios?
>
> Thanks
> ----- Original Message ----- From: "Juan Pablo Pizarro"
> <juanpablo.pizarro@(protected)>
> To: "Struts Users Mailing List" <user@(protected)>
> Sent: Sunday, June 01, 2008 11:30 AM
> Subject: Re: Are sessions confused?
>
>
>
> > Yes I know, but my application was struts2-blank-2.0.11.1.war (from
> > struts-2.0.11.1-all.zip). Then I coded a bit and I posted that.
> >
> > JP
> >
> > 2008/6/1 Dave Newton <newton.dave@(protected)>:
> >
> > > --- On Fri, 5/30/08, Juan Pablo Pizarro wrote:
> > >
> > > > With
> ServletActionContext.getRequest().getSession().setAttribute("user",
> > > > (int) (Math.random() * 100)); the problem is only in
> > > > firefox!!.
> > > >
> > >
> > > If you're on different machines and seeing the wrong session data on
> them then something is broken with your application. I've never seen this in
> S2 and as said before most of us here are using S2 sessions without any
> issues.
> > >
> > > Dave
> > >
> > >
> > >
> ---------------------------------------------------------------------
> > > To unsubscribe, e-mail:
> user-unsubscribe@(protected)
> > > For additional commands, e-mail: user-help@(protected)
> > >
> > >
> > >
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> user-unsubscribe@(protected)
> > For additional commands, e-mail: user-help@(protected)
> >
> >
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>
>

Attachment: user_187100.ezm (zipped)
Do you have a caching proxy between you and the server? If so try going
directly to the server.

Juan Pablo Pizarro wrote:
> Yes, the effect is the same.. :( everything is ok, but when I pressed
> ctrl+f5, the sessions are the last again.
>
> How you put thing in the session from a action?
>
> 2008/6/1, Martin <mgainty@(protected)>:
>  
>> can you display the session_id from your test scenarios?
>>
>> Thanks
>> ----- Original Message ----- From: "Juan Pablo Pizarro"
>> <juanpablo.pizarro@(protected)>
>> To: "Struts Users Mailing List" <user@(protected)>
>> Sent: Sunday, June 01, 2008 11:30 AM
>> Subject: Re: Are sessions confused?
>>
>>
>>
>>  
>>> Yes I know, but my application was struts2-blank-2.0.11.1.war (from
>>> struts-2.0.11.1-all.zip). Then I coded a bit and I posted that.
>>>
>>> JP
>>>
>>> 2008/6/1 Dave Newton <newton.dave@(protected)>:
>>>
>>>    
>>>> --- On Fri, 5/30/08, Juan Pablo Pizarro wrote:
>>>>
>>>>      
>>>>> With
>>>>>      
>> ServletActionContext.getRequest().getSession().setAttribute("user",
>>  
>>>>> (int) (Math.random() * 100)); the problem is only in
>>>>> firefox!!.
>>>>>
>>>>>      
>>>> If you're on different machines and seeing the wrong session data on
>>>>      
>> them then something is broken with your application. I've never seen this in
>> S2 and as said before most of us here are using S2 sessions without any
>> issues.
>>  
>>>> Dave
>>>>
>>>>
>>>>
>>>>      
>> ---------------------------------------------------------------------
>>  
>>>> To unsubscribe, e-mail:
>>>>      
>> user-unsubscribe@(protected)
>>  
>>>> For additional commands, e-mail: user-help@(protected)
>>>>
>>>>
>>>>
>>>>      
>>>    
>> ---------------------------------------------------------------------
>>  
>>> To unsubscribe, e-mail:
>>>    
>> user-unsubscribe@(protected)
>>  
>>> For additional commands, e-mail: user-help@(protected)
>>>
>>>
>>>
>>>    
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscribe@(protected)
>> For additional commands, e-mail: user-help@(protected)
>>
>>
>>  
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>
>  


Attachment: user_187109.ezm (zipped)
No, I haven't. Now my application is working, then, i suspect that the
problem was external and maybe the networking personel had a proxy or
something like that. I'm asking them. In my pc, I haven't.

I'll download tomcat again to test in my house.



2008/6/2 Al Sutton <al.sutton@(protected)>:
> Do you have a caching proxy between you and the server? If so try going
> directly to the server.
>
> Juan Pablo Pizarro wrote:
>>
>> Yes, the effect is the same.. :( everything is ok, but when I pressed
>> ctrl+f5, the sessions are the last again.
>>
>> How you put thing in the session from a action?
>>
>> 2008/6/1, Martin <mgainty@(protected)>:
>>
>>>
>>> can you display the session_id from your test scenarios?
>>>
>>> Thanks
>>> ----- Original Message ----- From: "Juan Pablo Pizarro"
>>> <juanpablo.pizarro@(protected)>
>>> To: "Struts Users Mailing List" <user@(protected)>
>>> Sent: Sunday, June 01, 2008 11:30 AM
>>> Subject: Re: Are sessions confused?
>>>
>>>
>>>
>>>
>>>>
>>>> Yes I know, but my application was struts2-blank-2.0.11.1.war (from
>>>> struts-2.0.11.1-all.zip). Then I coded a bit and I posted that.
>>>>
>>>> JP
>>>>
>>>> 2008/6/1 Dave Newton <newton.dave@(protected)>:
>>>>
>>>>
>>>>>
>>>>> --- On Fri, 5/30/08, Juan Pablo Pizarro wrote:
>>>>>
>>>>>
>>>>>>
>>>>>> With
>>>>>>
>>>
>>> ServletActionContext.getRequest().getSession().setAttribute("user",
>>>
>>>>>>
>>>>>> (int) (Math.random() * 100)); the problem is only in
>>>>>> firefox!!.
>>>>>>
>>>>>>
>>>>>
>>>>> If you're on different machines and seeing the wrong session data on
>>>>>
>>>
>>> them then something is broken with your application. I've never seen this
>>> in
>>> S2 and as said before most of us here are using S2 sessions without any
>>> issues.
>>>
>>>>>
>>>>> Dave
>>>>>
>>>>>
>>>>>
>>>>>
>>>
>>> ---------------------------------------------------------------------
>>>
>>>>>
>>>>> To unsubscribe, e-mail:
>>>>>
>>>
>>> user-unsubscribe@(protected)
>>>
>>>>>
>>>>> For additional commands, e-mail: user-help@(protected)
>>>>>
>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>> ---------------------------------------------------------------------
>>>
>>>>
>>>> To unsubscribe, e-mail:
>>>>
>>>
>>> user-unsubscribe@(protected)
>>>
>>>>
>>>> For additional commands, e-mail: user-help@(protected)
>>>>
>>>>
>>>>
>>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: user-unsubscribe@(protected)
>>> For additional commands, e-mail: user-help@(protected)
>>>
>>>
>>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscribe@(protected)
>> For additional commands, e-mail: user-help@(protected)
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>
>

Attachment: user_187092.ezm (zipped)
Not sure of the affected code. It happens periodically on all our
secure pages. My thoughts are just guesses at this point.

Thanks for you help,
Paula

-----Original Message-----
From: Martin Gainty [mailto:mgainty@(protected)]
Sent: Saturday, May 31, 2008 10:49 AM
To: Struts Users Mailing List
Subject: RE: Session Data overlap?


very little we can help you with until we see the effected code
for example we have account Name clearly scoped as session
<s:set name="accountName" value="accountName" scope="session" />not much
room for obfuscation here as the jobz object is clearly scoped as
request
<s:property value="#session\['accountName'\]"/>

HTH
Martin
______________________________________________
Disclaimer and confidentiality note
Everything in this e-mail and any attachments relates to the official
business of Sender. This transmission is of a confidential nature and
Sender does not endorse distribution to any party other than intended
recipient. Sender does not necessarily endorse content contained within
this transmission.


> Subject: RE: Session Data overlap?
> Date: Sat, 31 May 2008 09:17:33 -0500
> From: Paula.McDowell@(protected)
> To: user@(protected)
>
> My thoughts too, but this is when the sharing begins displaying the
data
> from another user's session. Not realizing it is NOT their account
> information they proceed with submitting the form for an update. For
> example, pay bill. Without looking at the account information on the
> screen, the user assumes that since they authenticated with their user
> id and password that it is THEIR account information being displayed,
so
> they continue with entering payment information and submitting the
form.
> Originally, it was the account stored in session, but at some point,
for
> example when the pay bill page displayed, it was using the account
> object from another user's session.
>
> I'm not sure why we are having the issue of session data being shared.
> I'm resorting to finding someone who has either seen something similar
> or can recommend a workaround.
>
> Any suggestion at this point will be extremely helpful!
>
> Paula
>
> -----Original Message-----
> From: news [mailto:news@(protected)
> Sent: Thursday, May 29, 2008 5:59 PM
> To: user@(protected)
> Subject: Re: Session Data overlap?
>
> That wouldn't be an issue, in and of itself; it's normal usage. What
> makes you think that's the source of the problem?
>
> L.
>
> McDowell, Paula wrote:
> > There are session variables that are used in the jsps to display the
> > account information. I think it's here where the problem lies, but
> I'm
> > not sure why. Here is an example of the account session variable
> being
> > used on the page. Any thoughts as to why this would be an issue?
> >
> > Thanks,
> > Paula
> >
> > <tr>
> >  <td>
> >    <c:out value="${account.custName}" />
> >  </td>
> > </tr>
> >
> > -----Original Message-----
> > From: Dave Newton [mailto:newton.dave@(protected)]
> > Sent: Thursday, May 29, 2008 10:38 AM
> > To: Struts Users Mailing List
> > Subject: RE: Session Data overlap?
> >
> > --- "McDowell, Paula" <Paula.McDowell@(protected):
> >> Thanks. I don't have any static variables. . . I'm assuming you
are
> >> speaking of the contextRelative attribute on forwards? If not,
> >> please explain actions defined as Context-level.
> >
> > I think he was asking if your actions have any member variables that
> > shouldn't be shared across requests/sessions/etc.
> >
> > Dave
> >
> >
> >
---------------------------------------------------------------------
> > To unsubscribe, e-mail: user-unsubscribe@(protected)
> > For additional commands, e-mail: user-help@(protected)
> >
> >
> > Private and confidential as detailed here:
> http://www.sug.com/disclaimers/default.htm#Mail . If you cannot access
> the link, please e-mail sender.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>
>
> Private and confidential as detailed here:
http://www.sug.com/disclaimers/default.htm#Mail . If you cannot access
the link, please e-mail sender.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>

_________________________________________________________________
Keep your kids safer online with Windows Live Family Safety.
http://www.windowslive.com/family_safety/overview.html?ocid=TXT_TAGLM_WL
_Refresh_family_safety_052008

Private and confidential as detailed here: http://www.sug.com/disclaimers/default.htm#Mail . If you cannot access the link, please e-mail sender.

Attachment: user_187093.ezm (zipped)
--- On Sun, 6/1/08, McDowell, Paula <Paula.McDowell@(protected):
> It happens periodically on all our secure pages.

*Only* the secure pages?

Dave


Attachment: user_187095.ezm (zipped)
Yes. These are the only pages that display session "account"
information.

-----Original Message-----
From: Dave Newton [mailto:newton.dave@(protected)]
Sent: Sunday, June 01, 2008 1:50 PM
To: Struts Users Mailing List
Subject: [OT] RE: Session Data overlap?

--- On Sun, 6/1/08, McDowell, Paula <Paula.McDowell@(protected):
> It happens periodically on all our secure pages.

*Only* the secure pages?

Dave


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


Private and confidential as detailed here: http://www.sug.com/disclaimers/default.htm#Mail . If you cannot access the link, please e-mail sender.

Attachment: user_187097.ezm (zipped)


-----Original Message-----
From: Dave Newton <newton.dave@(protected)>
Sent: June 01, 2008 1:50 PM
To: Struts Users Mailing List <user@(protected)>
Subject: [OT] RE: Session Data overlap?

--- On Sun, 6/1/08, McDowell, Paula <Paula.McDowell@(protected):
> It happens periodically on all our secure pages.

*Only* the secure pages?

Dave


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



Attachment: user_187094.ezm (zipped)
That issue is closed, although there is a comment left after it was closed
suggesting that the issue is still a problem and that the bug should be re-opened.

I see this 'warning' from OGNL wherever I use Action-Redirect results with the
latest struts2 version, and it's true that the stacktrace in the webserver log
is distracting, but I don't find any problems with it like the last comment
suggests.

It's not clear why the poster of that comment didn't re-open the bug or create a
new one if there is a real problem there.

Do you find problems with it still?

It seems to me that the issue should not have been changed from status open to
resolved, rather it should have been changed from priority major to enhancement.

Also the poster of the last comment should have left more details with perhaps a
patch or unit-test displaying his/her bug.


Adam


Mark Lester on 30/05/08 14:31, wrote:
> Thanks for the quick response. I don't think that is the problem
> because that directory is already clear plus I have only used the
> current version of struts2
>
> -----Original Message-----
> From: Owen Berry [mailto:owen.berry@(protected)]
> Sent: Friday, May 30, 2008 9:24 AM
> To: Struts Users Mailing List
> Subject: Re: Action-Redirect Parameter Problem
>
> If you're using Maven, you should try clearing out your local Maven
> repository (rm -rf ~/.m2/repository) and try again ... I've had a few
> cases where I seemed to be using old versions of jars until I did
> this.
>
> On Fri, May 30, 2008 at 9:18 AM, Mark Lester <MarkL@(protected)>
> wrote:
>> I followed the
>> http://struts.apache.org/2.x/docs/redirect-action-result.html To
> pass
>> parameters to an action
>>
>> And it generates the exception
>>
>> Caught OgnlException while setting property 'navigation' on type
>> 'org.apache.struts2.dispatcher.ServletActionRedirectResult'.
>>
>>
>>
>> I looked the Exception up and I found a bug report for struts 2 at
>>
>> http://issues.apache.org/struts/browse/WW-1714
>>
>>
>>
>> The problem is that it says the issue is resolved as of version 2.08
>> but I am using 2.11 and I am still getting the warning.
>>
>> Information regarding this issue would be very helpful.


Attachment: user_187106.ezm (zipped)
Yeah I am still having problems with it.

-----Original Message-----
From: Adam Hardy [mailto:ahardy.struts@(protected)]
Sent: Sunday, June 01, 2008 2:52 PM
To: Struts Users Mailing List
Subject: Re: Action-Redirect Parameter Problem

That issue is closed, although there is a comment left after it was
closed
suggesting that the issue is still a problem and that the bug should
be re-opened.

I see this 'warning' from OGNL wherever I use Action-Redirect results
with the
latest struts2 version, and it's true that the stacktrace in the
webserver log
is distracting, but I don't find any problems with it like the last
comment
suggests.

It's not clear why the poster of that comment didn't re-open the bug
or create a
new one if there is a real problem there.

Do you find problems with it still?

It seems to me that the issue should not have been changed from status
open to
resolved, rather it should have been changed from priority major to
enhancement.

Also the poster of the last comment should have left more details with
perhaps a
patch or unit-test displaying his/her bug.


Adam


Mark Lester on 30/05/08 14:31, wrote:
> Thanks for the quick response. I don't think that is the problem
> because that directory is already clear plus I have only used the
> current version of struts2
>
> -----Original Message-----
> From: Owen Berry [mailto:owen.berry@(protected)]
> Sent: Friday, May 30, 2008 9:24 AM
> To: Struts Users Mailing List
> Subject: Re: Action-Redirect Parameter Problem
>
> If you're using Maven, you should try clearing out your local Maven
> repository (rm -rf ~/.m2/repository) and try again ... I've had a
few
> cases where I seemed to be using old versions of jars until I did
> this.
>
> On Fri, May 30, 2008 at 9:18 AM, Mark Lester <MarkL@(protected)>
> wrote:
>> I followed the
>> http://struts.apache.org/2.x/docs/redirect-action-result.html To
> pass
>> parameters to an action
>>
>> And it generates the exception
>>
>> Caught OgnlException while setting property 'navigation' on type
>> 'org.apache.struts2.dispatcher.ServletActionRedirectResult'.
>>
>>
>>
>> I looked the Exception up and I found a bug report for struts 2 at
>>
>> http://issues.apache.org/struts/browse/WW-1714
>>
>>
>>
>> The problem is that it says the issue is resolved as of version
2.08
>> but I am using 2.11 and I am still getting the warning.
>>
>> Information regarding this issue would be very helpful.


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


Attachment: user_187108.ezm (zipped)
I had a look at the code and I can see why it throws an exception at that point,
but despite that, my experience is that it works - it does set the parameter on
my Result.

Mark Lester on 02/06/08 13:08, wrote:
> Yeah I am still having problems with it.
>
> -----Original Message-----
> From: Adam Hardy [mailto:ahardy.struts@(protected)]
> Sent: Sunday, June 01, 2008 2:52 PM
> To: Struts Users Mailing List
> Subject: Re: Action-Redirect Parameter Problem
>
> That issue is closed, although there is a comment left after it was
> closed
> suggesting that the issue is still a problem and that the bug should
> be re-opened.
>
> I see this 'warning' from OGNL wherever I use Action-Redirect results
> with the
> latest struts2 version, and it's true that the stacktrace in the
> webserver log
> is distracting, but I don't find any problems with it like the last
> comment
> suggests.
>
> It's not clear why the poster of that comment didn't re-open the bug
> or create a
> new one if there is a real problem there.
>
> Do you find problems with it still?
>
> It seems to me that the issue should not have been changed from status
> open to
> resolved, rather it should have been changed from priority major to
> enhancement.
>
> Also the poster of the last comment should have left more details with
> perhaps a
> patch or unit-test displaying his/her bug.
>
>
> Adam
>
>
> Mark Lester on 30/05/08 14:31, wrote:
>> Thanks for the quick response. I don't think that is the problem
>> because that directory is already clear plus I have only used the
>> current version of struts2
>>
>> -----Original Message-----
>> From: Owen Berry [mailto:owen.berry@(protected)]
>> Sent: Friday, May 30, 2008 9:24 AM
>> To: Struts Users Mailing List
>> Subject: Re: Action-Redirect Parameter Problem
>>
>> If you're using Maven, you should try clearing out your local Maven
>> repository (rm -rf ~/.m2/repository) and try again ... I've had a
> few
>> cases where I seemed to be using old versions of jars until I did
>> this.
>>
>> On Fri, May 30, 2008 at 9:18 AM, Mark Lester <MarkL@(protected)>
>> wrote:
>>> I followed the
>>> http://struts.apache.org/2.x/docs/redirect-action-result.html To
>> pass
>>> parameters to an action
>>>
>>> And it generates the exception
>>>
>>> Caught OgnlException while setting property 'navigation' on type
>>> 'org.apache.struts2.dispatcher.ServletActionRedirectResult'.
>>>
>>>
>>>
>>> I looked the Exception up and I found a bug report for struts 2 at
>>>
>>> http://issues.apache.org/struts/browse/WW-1714
>>>
>>>
>>>
>>> The problem is that it says the issue is resolved as of version
> 2.08
>>> but I am using 2.11 and I am still getting the warning.
>>>
>>> Information regarding this issue would be very helpful.


Attachment: user_187096.ezm (zipped)
Hi all,

I meet a problem on populating array properties...
here is the detail description:

public class User {
    String [] phone;
    public String[] getPhone(){
        return phone;
    }
    public void setPhone(String[] phone) {
        this.phone=phone;
    }
}

public class UserAction {
    private User user=new User();

    public User getUser(){ return user;}
    public void setUser(User user) { this.user=user;}

    public String execute() {
           // user.getPhone() always return null...
    }

}


And i have a jsp which will submit a list of phone to the action class


<form name=xxx action=xxx>
   <input type=text name="user.phone" />
   <input type=text name="user.phone" />
   <input type=text name="user.phone" />
    <input type=submit name=submit value=submit/>
</form>


after the form is submitted... the action class is called, however the list
of phone can't be populated to the user object in the UserAction class...
i have tried if the phone is not a array type.. the property is populated to
the user object ...
any suggestion for the issue?
thx alot!

Attachment: user_187099.ezm (zipped)
try using List,

public class User {
    //String [] phone;
    private List <String> phone;

  public List<String> getPhone() {
    return phone;
  }

  public void setPhone(List<String> phone) {
    this.phone = phone;
  }
   
}

the JSP
<form name="XXX" action="XXX">
   <input type=text name="user.phone[0]" />
   <input type=text name="user.phone[1]" />
   <input type=text name="user.phone[2]" />
    <input type=submit name=submit value=submit/>
</form>


And the action

U didn't have to f this
>>>>>>>>> private User user=new User();

just

  private User user;
  public User getUser(){ return user;}
  public void setUser(User user) { this.user=user;}


    Iterator it = getUser().getPhone().iterator();
    while (it.hasNext()) {
       Object object = it.next();
       System.out.print(object);
    }

Jacky Shih wrote:
> Hi all,
>
> I meet a problem on populating array properties...
> here is the detail description:
>
> public class User {
>     String [] phone;
>     public String[] getPhone(){
>         return phone;
>     }
>     public void setPhone(String[] phone) {
>         this.phone=phone;
>     }
> }
>
> public class UserAction {
>      private User user=new User();
>
>      public User getUser(){ return user;}
>      public void setUser(User user) { this.user=user;}
>
>      public String execute() {
>             // user.getPhone() always return null...
>      }
>
> }
>
>
> And i have a jsp which will submit a list of phone to the action class
>
>
> <form name=xxx action=xxx>
>     <input type=text name="user.phone" />
>     <input type=text name="user.phone" />
>     <input type=text name="user.phone" />
>     <input type=submit name=submit value=submit/>
> </form>
>
>
> after the form is submitted... the action class is called, however the list
> of phone can't be populated to the user object in the UserAction class...
> i have tried if the phone is not a array type.. the property is populated to
> the user object ...
> any suggestion for the issue?
> thx alot!
>
>  


Attachment: user_187117.ezm (zipped)
It is not working even i changed String array to List and append the index
in the jsp form....

This method works in Struts1.x...but what should i do to make it functioning
in Struts 2?

can anyone help?

On Mon, Jun 2, 2008 at 11:38 AM, l4kyl4ky@(protected)>
wrote:

> try using List,
>
> public class User {
>    //String [] phone;
>     private List <String> phone;
>
>  public List<String> getPhone() {
>     return phone;
>  }
>
>  public void setPhone(List<String> phone) {
>     this.phone = phone;
>  }
>   }
>
> the JSP
> <form name="XXX" action="XXX">
>   <input type=text name="user.phone[0]" />
>   <input type=text name="user.phone[1]" />
>   <input type=text name="user.phone[2]" />
>    <input type=submit name=submit value=submit/>
> </form>
>
>
> And the action
>
> U didn't have to f this
>
>>   private User user=new User();
>>>>>>>>>>
>>>>>>>>>
> just
>
>  private User user;
>  public User getUser(){ return user;}
>  public void setUser(User user) { this.user=user;}
>
>
>     Iterator it = getUser().getPhone().iterator();
>     while (it.hasNext()) {
>       Object object = it.next();
>       System.out.print(object);
>
>     }
>
> Jacky Shih wrote:
>
>> Hi all,
>>
>> I meet a problem on populating array properties...
>> here is the detail description:
>>
>> public class User {
>>     String [] phone;
>>     public String[] getPhone(){
>>         return phone;
>>     }
>>     public void setPhone(String[] phone) {
>>         this.phone=phone;
>>     }
>> }
>>
>> public class UserAction {
>>     private User user=new User();
>>
>>     public User getUser(){ return user;}
>>     public void setUser(User user) { this.user=user;}
>>
>>     public String execute() {
>>            // user.getPhone() always return null...
>>     }
>>
>> }
>>
>>
>> And i have a jsp which will submit a list of phone to the action class
>>
>>
>> <form name=xxx action=xxx>
>>    <input type=text name="user.phone" />
>>    <input type=text name="user.phone" />
>>    <input type=text name="user.phone" />
>>     <input type=submit name=submit value=submit/>
>> </form>
>>
>>
>> after the form is submitted... the action class is called, however the
>> list
>> of phone can't be populated to the user object in the UserAction class...
>> i have tried if the phone is not a array type.. the property is populated
>> to
>> the user object ...
>> any suggestion for the issue?
>> thx alot!
>>
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>
>

Attachment: user_187098.ezm (zipped)
I am using Struts-2.0.11.1.

Does anyone know of documentation explaining how to build a more robust "handler"
functions?

Literally, the best I've seen is below. What if I want to make the request to a new URL?

 function handler(widget, node) {
  alert('I will handle this myself!');
  node.innerHTML = "Done";
 }


   

Attachment: user_187101.ezm (zipped)
Hi,

I've used Struts in the past but have spent a few years working with
other technologies.

I would like to come back to Struts again however and thought I'd look
at Struts 2.

I was hoping to set up a project in Eclipse however I'm struggling
with it. I found this article in the archives, dated October 2006 -
http://www.nabble.com/Struts2-runs-in-Eclipse-td6981946.html#a6981946
- however I haven't found it answers all my questions.

I have managed to create a project as suggested, however I have no
idea now how to Run it. I was hoping to be able to right click on the
project and select "Run on Server" but that doesn't seem to be an
option.

Can anyone please share with me their secrets as to how to easily
start up a Struts 2 project in Eclipse?

Many thanks,
Andrew.

Attachment: user_187105.ezm (zipped)
It's no different than with any other Java server app.

You might have more luck checking Eclipse forums/lists for specific info; I don't know of any particular issues with an S2 app.

Dave

--- On Mon, 6/2/08, Andrew Myers <am2605@(protected):

> From: Andrew Myers <am2605@(protected)>
> Subject: Struts 2 / Eclipse
> To: user@(protected)
> Date: Monday, June 2, 2008, 3:17 AM
> Hi,
>
> I've used Struts in the past but have spent a few years
> working with
> other technologies.
>
> I would like to come back to Struts again however and
> thought I'd look
> at Struts 2.
>
> I was hoping to set up a project in Eclipse however I'm
> struggling
> with it. I found this article in the archives, dated
> October 2006 -
> http://www.nabble.com/Struts2-runs-in-Eclipse-td6981946.html#a6981946
> - however I haven't found it answers all my questions.
>
> I have managed to create a project as suggested, however I
> have no
> idea now how to Run it. I was hoping to be able to right
> click on the
> project and select "Run on Server" but that
> doesn't seem to be an
> option.
>
> Can anyone please share with me their secrets as to how to
> easily
> start up a Struts 2 project in Eclipse?
>
> Many thanks,
> Andrew.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail:
> user-help@(protected)

Attachment: user_187107.ezm (zipped)

download tomcat-plugin from
http://www.eclipsetotale.com/tomcatPlugin.html

setup tomcat in eclipse (assume $ECLIPSE_HOME is the folder where eclipse was unzipped)
unzip the zip file to $ECLIPSE_HOME/plugins folder

from eclipse folder
java -jar startup.jar -clean
Window/Preferences/Tomcat Manager App
supply the required parameters of tomcat-home tomcat-version and context-declaration-mode Server.xml

setup the tomcat-plugin manager app to execute on port which is not previously bound e.g.
http://localhost:8081/manager

feel free to ping me offline for any details

HTH
Martin
______________________________________________
Disclaimer and confidentiality note
Everything in this e-mail and any attachments relates to the official business of Sender. This transmission is of a confidential nature and Sender does not endorse distribution to any party other than intended recipient. Sender does not necessarily endorse content contained within this transmission.


> Date: Mon, 2 Jun 2008 04:56:27 -0700
> From: newton.dave@(protected)
> Subject: Re: Struts 2 / Eclipse
> To: user@(protected)
>
> It's no different than with any other Java server app.
>
> You might have more luck checking Eclipse forums/lists for specific info; I don't know of any particular issues with an S2 app.
>
> Dave
>
> --- On Mon, 6/2/08, Andrew Myers <am2605@(protected):
>
> > From: Andrew Myers <am2605@(protected)>
> > Subject: Struts 2 / Eclipse
> > To: user@(protected)
> > Date: Monday, June 2, 2008, 3:17 AM
> > Hi,
> >
> > I've used Struts in the past but have spent a few years
> > working with
> > other technologies.
> >
> > I would like to come back to Struts again however and
> > thought I'd look
> > at Struts 2.
> >
> > I was hoping to set up a project in Eclipse however I'm
> > struggling
> > with it. I found this article in the archives, dated
> > October 2006 -
> > http://www.nabble.com/Struts2-runs-in-Eclipse-td6981946.html#a6981946
> > - however I haven't found it answers all my questions.
> >
> > I have managed to create a project as suggested, however I
> > have no
> > idea now how to Run it. I was hoping to be able to right
> > click on the
> > project and select "Run on Server" but that
> > doesn't seem to be an
> > option.
> >
> > Can anyone please share with me their secrets as to how to
> > easily
> > start up a Struts 2 project in Eclipse?
> >
> > Many thanks,
> > Andrew.
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: user-unsubscribe@(protected)
> > For additional commands, e-mail:
> > user-help@(protected)
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@(protected)
> For additional commands, e-mail: user-help@(protected)
>

_________________________________________________________________
Keep your kids safer online with Windows Live Family Safety.
http://www.windowslive.com/family_safety/overview.html?ocid=TXT_TAGLM_WL_Refresh_family_safety_052008

Attachment: user_187110.ezm (zipped)
Hi Andrew,

I had the same problem some weeks ago and did it the following way:

I prefer to use the Sysdeo Eclipse Tomcat Launcher plugin (http://www.eclipsetotale.com/tomcatPlugin.html). This gives you integrated Tomcat start/stop functionality and also adds a "Tomcat project" which gives you the basic infrastructure of a web app.
Then I copy the files from a working Struts (2) application into this project. The Struts blank application is a good (and minimal) choice. With this you do have the basics of a Struts based web app in an Eclipse project.
You will have to do some tuning (e. g. add the libraries which you copied to WEB-INF/lib to your build path, adapt the package structure, ...). I had a bit to fight with the Struts Blank app packages but renaming them helped.

If you are interested I can send you a zipped minimal project generated this way. It should work even if you are not using the plugin. In that case you probably have to add the servlet jars manually to the project.

Martin


----- Original Nachricht ----

> From: Andrew Myers <am2605@(protected)>
> Subject: Struts 2 / Eclipse
> To: user@(protected)
> Date: Monday, June 2, 2008, 3:17 AM
> Hi,
>
> I've used Struts in the past but have spent a few years
> working with
> other technologies.
>
> I would like to come back to Struts again however and
> thought I'd look
> at Struts 2.
>
> I was hoping to set up a project in Eclipse however I'm
> struggling
> with it. I found this article in the archives, dated
> October 2006 -
> http://www.nabble.com/Struts2-runs-in-Eclipse-td6981946.html#a6981946
> - however I haven't found it answers all my questions.
>
> I have managed to create a project as suggested, however I
> have no
> idea now how to Run it. I was hoping to be able to right
> click on the
> project and select "Run on Server" but that
> doesn't seem to be an
> option.
>
> Can anyone please share with me their secrets as to how to
> easily
> start up a Struts 2 project in Eclipse?
>
> Many thanks,
> Andrew.
>


Attachment: user_187111.ezm (zipped)
I always use maven and it is quite easy:

http://struts.apache.org/2.1.2/docs/struts-maven-archetypes.html

after you have your blank project created, just do a :

mvn eclipse:eclipse -Dwtpversion=1.5

in the project directory and import the generated project into
eclipse. After that, just run it using WTP as usual.

musachy

On Mon, Jun 2, 2008 at 3:17 AM, Andrew Myers <am2605@(protected):
> Hi,
>
> I've used Struts in the past but have spent a few years working with
> other technologies.
>
> I would like to come back to Struts again however and thought I'd look
> at Struts 2.
>
> I was hoping to set up a project in Eclipse however I'm struggling
> with it. I found this article in the archives, dated October 2006 -
> http://www.nabble.com/Struts2-runs-in-Eclipse-td6981946.html#a6981946
> - however I haven't found it answers all my questions.
>
> I have managed to create a project as suggested, however I have no
> idea now how to Run it. I was hoping to be able to right click on the
> project and select "Run on Server" but that doesn't seem to be an
> option.
>
> Can anyone please share with me their secrets as to how to easily
> start up a Struts 2 project in Eclipse?
>
> Many thanks,
> Andrew.
>
> ---------------------------------------------------------------------
> 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_187102.ezm (zipped)

Hi,

with onchange="submit() I loose the ajax functionality -> website gets
completely refreshed



Jim Kiley wrote:
>
> onchange="submit();"
>
> On Fri, May 30, 2008 at 6:26 AM, zeermi <kutzi@(protected):
>
>>
>> Hi,
>>
>> I think this is an easy question to struts2 insiders ... but I wasted
>> serveral hours and could not solve the problem.
>>
>> I have one div and one form
>>
>> I refresh the div with the forms content by clicking submit:
>>
>> <s:submit value="submit" theme="ajax" targets="divid"/>
>>
>> This works fine . But I dont want to click the submit button,I want this
>> after an onchange event like:
>>
>> <s:textfield theme="ajax" name='data' onchange="?????"></s:textfield>
>>
>>
>> I hope anybody can help me ;/
>> thank you
>> zeermi
>>
>>
>>
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Struts2-onchange-event-should-do-the-same-like-submit%28with-ajax-tag%29.-How---tp17555869p17555869.html
>> 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)
>>
>>
>
>
> --
> Jim Kiley
> Technical Consultant | Summa
> [p] 412.258.3346 [m] 412.445.1729
> http://www.summa-tech.com
>
>

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


Attachment: user_187103.ezm (zipped)

Hi all
     I am using struts 1.3.5 for my web tire and im using springs for my
other business operations. I am in need of two actions to be chained
(coupled) to accomplish a task in a senario... say

      i have to chain the /addreview to /showfriendsEmail url so i
have used the struts-config to achive it
    every thing is working fine when i use redirect=true (which is
simillar to sendRedirect) if i left that attribute in my forward tag its
throwing no bean specified.

i suspect that its due to both the actions have bean handled by same form
bean object with different instance names say reviewform and emaillistform
can any one suggest me a way to solve this.
  why i suspect is i am chaining the /addreview to /showuserregistration
with out any redirect attribute which is workin fine but it uses different
form bean object.

<form-bean name="reviewform" type="hca.form.review.ReviewBean"/>
<form-bean name="emaillistform" type="hca.form.review.ReviewBean"/>
<form-bean name="userform" type="hca.form.user.UserBean"/>

<action path="/addreview"
          type="org.springframework.web.struts.DelegatingActionProxy"
          name="reviewform"
          scope="session"
          input="AddReviewDef"
          validate="true">
       <forward name="showUserRegistrationPage"
path="/showuserregistration.html" />
       <forward name="showInvitationPage" path="/showfriendsEmail.html"
redirect="true"/>
    </action>

<action path="/showfriendsEmail"
       type="org.springframework.web.struts.DelegatingActionProxy"
       name="emaillistform"
       validate="false"
       scope="session">
       <forward name="showFriendsEmailPage" path="FriendsEmailPageDef"
/>
    </action>

<action path="/showuserregistration"
        type="org.springframework.web.struts.DelegatingActionProxy"
        name="userform"
        validate="false"
        input="UserRegistrationDef"
        scope="session">
        <forward name="showRegistrationPage"
path="UserRegistrationDef"/>
        <forward name="showEditRegistrationPage"
path="EditRegistrationDef"/>
       
    </action>
--
Sent from the Struts - User mailing list archive at Nabble.com.


Attachment: user_187104.ezm (zipped)

Please help

Does anyone have a web application with Struts 2 internationalized and a
Linux server?

Maybe I need to configure JBOSS?


Regalut wrote:
>
> Hello:
>
> I am using i18nInterceptor for that my page can be seen in Spanish or
> English, and everything works well in Windows.
> The problem is that i have mounted a server on Linux (Red Hat Enterprise
> 5) with JBoss 4.2, and no longer work the internationalization.
>
> Do I have to set something on Linux for i18n?
>

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


Attachment: user_187112.ezm (zipped)
Nobody have any hint why my attribute is not set in action class when link is clicked in jsp ?

Milan Milanovic <milanmilanovich@(protected),

I have currentPage int attribute in my action class and I want when user click in my jsp to set currentPage attribute. I tried it like this (pages is a list of int values):


 
   
 

 


But, curentPage is not set at all ? I checked in method which is response to the "list.action", it is always 0. What is wrong here ?

--
Thx, Milan

   

   

Attachment: user_187113.ezm (zipped)
use this instead:

<s:param name="currentPage" value="%{property}" />

musachy

On Fri, May 30, 2008 at 11:48 AM, Milan Milanovic
<milanmilanovich@(protected):
> Hi,
>
> I have currentPage int attribute in my action class and I want when user click in my jsp to set currentPage attribute. I tried it like this (pages is a list of int values):
>
> <s:iterator value="pages">
>   <s:url id="url" action="list.action" >
>     <s:param name="currentPage" value="<s:property/>" />
>   </s:url>
>
>   <s:a href="%{url}" theme="ajax" notifyTopics="/refresh"><s:property/></s:a>
> </s:iterator>
>
> But, curentPage is not set at all ? I checked in method which is response to the "list.action", it is always 0. What is wrong here ?
>
> --
> Thx, Milan
>
>



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

Attachment: user_187114.ezm (zipped)
I tried this, but it doesn't set "currentPage" at all.

Musachy Barroso <musachy@(protected):



musachy

On Fri, May 30, 2008 at 11:48 AM, Milan Milanovic
wrote:
> Hi,
>
> I have currentPage int attribute in my action class and I want when user click in my jsp to set currentPage attribute. I tried it like this (pages is a list of int values):
>
>
>  
>    
>  
>
>  
>
>
> But, curentPage is not set at all ? I checked in method which is response to the "list.action", it is always 0. What is wrong here ?
>
> --
> Thx, Milan
>
>



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

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



   

Attachment: user_187115.ezm (zipped)
That means it is not finding a value for that variable, try printing
it to the page and see if it has a value.

musachy

On Mon, Jun 2, 2008 at 9:34 AM, Milan Milanovic
<milanmilanovich@(protected):
> I tried this, but it doesn't set "currentPage" at all.
>
> Musachy Barroso <musachy@(protected):
>
>
>
> musachy
>
> On Fri, May 30, 2008 at 11:48 AM, Milan Milanovic
> wrote:
>> Hi,
>>
>> I have currentPage int attribute in my action class and I want when user click in my jsp to set currentPage attribute. I tried it like this (pages is a list of int values):
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> But, curentPage is not set at all ? I checked in method which is response to the "list.action", it is always 0. What is wrong here ?
>>
>> --
>> Thx, Milan
>>
>>
>
>
>
> --
> "Hey you! Would you help me to carry the stone?" Pink Floyd
>
> ---------------------------------------------------------------------
> 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_187116.ezm (zipped)
I checked now and setCurrentPage method is not called at all ?

Musachy Barroso <musachy@(protected)
it to the page and see if it has a value.

musachy

On Mon, Jun 2, 2008 at 9:34 AM, Milan Milanovic
wrote:
> I tried this, but it doesn't set "currentPage" at all.
>
> Musachy Barroso wrote: use this instead:
>
>
>
> musachy
>
> On Fri, May 30, 2008 at 11:48 AM, Milan Milanovic
> wrote:
>> Hi,
>>
>> I have currentPage int attribute in my action class and I want when user click in my jsp to set currentPage attribute. I tried it like this (pages is a list of int values):
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> But, curentPage is not set at all ? I checked in method which is response to the "list.action", it is always 0. What is wrong here ?
>>
>> --
>> Thx, Milan
>>
>>
>
>
>
> --
> "Hey you! Would you help me to carry the stone?" Pink Floyd
>
> ---------------------------------------------------------------------
> 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

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



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