[S2] Getting property value from Enum

2009-05-26 Thread Steven Yang
Hi First of all if this question has been ask, I apologize for the double post. and please refer me to the reference. thanks I am using 2.1.6. I have a Enum class Gender and it has a method getTextKey() which simply returns a key for me to use in getText() in Action If in my Action I have

Re: [S2] Getting property value from Enum

2009-05-26 Thread Steven Yang
Just want to add some more information if I do s:property value=gender.toString()/ s:property value=gender.name()/ s:property value=gender.cardinal()/ I get what is expected. I guess all native Enum methods are fine.

Re: RequiredString Validation doesn't work and AbstractValidationActionSupport is missing?

2009-05-26 Thread Niklas Johansson
Hello Dave, Thanks for all answers. Regarding the ParameterAware, I found the information here and it's specified as the preferred solution: http://struts.apache.org/2.1.6/docs/how-can-we-access-request-parameters-passed-into-an-action.html I have enough information below to do some test for

Re: [S2] Getting property value from Enum

2009-05-26 Thread Steven Yang
OMG I can't believe myself. how can i make such a stupid mistake Sorry guys for wasting your time. Its all my fault my method name was getTextkey() but I kept on using getTextKey() or textKey (capital K) thats why it never worked its solved.

Re: [S2] Getting property value from Enum

2009-05-26 Thread Matt Jiang
Don't worry, we all made this kind of mistake before. and this would not be the last time. bless you... On Tue, May 26, 2009 at 4:47 PM, Steven Yang kenshin...@gmail.com wrote: OMG I can't believe myself. how can i make such a stupid mistake Sorry guys for wasting your time. Its all my

Re: RequiredString Validation doesn't work and AbstractValidationActionSupport is missing?

2009-05-26 Thread Dave Newton
Niklas Johansson wrote: Regarding the ParameterAware, I found the information here and it's specified as the preferred solution: http://struts.apache.org/2.1.6/docs/how-can-we-access-request-parameters-passed-into-an-action.html It's the preferred solution for accessing the parameters

Re: not able to populate the productID or the productName from the front end jsp.

2009-05-26 Thread Prashant Singh
Hi Dave,   one of my action classes are executing perfectly which I am appending below. I am also including the output for you.   package net.astralpharma; import com.opensymphony.xwork2.ActionSupport; import java.sql.*; import java.util.*; public class Productdisplay extends ActionSupport  {  

Struts 2 dispatcher does not see namespace and action in URL

2009-05-26 Thread Mitchell, Steven
I have a Struts 2 application that runs fine under Tomcat 5.5 that will not run on a fully patched version of WebSphere 6.1. The application index.jsp page redirects to a mapped namespace and action, yet the Struts 2 dispatcher does not see the namespace or action. It issues the message There is

Re: Struts 2 dispatcher does not see namespace and action in URL

2009-05-26 Thread Terry Gardner
I vaguely remember something about WebSphere and Apache commons logging ... will try to dig it up. On May 26, 2009, at 9:22 AM, Mitchell, Steven wrote: I have a Struts 2 application that runs fine under Tomcat 5.5 that will not run on a fully patched version of WebSphere 6.1. The

RE: Struts 2 dispatcher does not see namespace and action in URL

2009-05-26 Thread Martin Gainty
did ibm provide any solution to these problems with their AppServer? http://www.networkworld.com/news/2009/032609-ibm-layoffs.html in the meanwhile just to get a working AppSever can you port over to Glassfish? easy to port..very simple to administer and a very knowledgeable and helpful staff!

Re: Keep Action Properties over multiple requests

2009-05-26 Thread Richard Sayre
Is it possible to specify all action properties in session param tag using regex or wildcards? On Mon, May 25, 2009 at 8:39 AM, Nils-Helge Garli Hegvik nil...@gmail.com wrote: Yes, the ScopeInterceptor should be able to handle this case. Nils-H On Mon, May 25, 2009 at 1:02 PM, Richard

s:select list and pre-selected item

2009-05-26 Thread Bas Schulte
Hi, I'm pretty much stumped about this one. I have a list of countries (ListCountry) that I return from my action to the view .jsp. I can render the select list just fine, this is the outputted html: select name=activity.location.address.country id=update-activity-

Re: s:select list and pre-selected item

2009-05-26 Thread Paweł Wielgus
Hi Bas, is your edited activity.location.address.country equal to 4122? If so it will be selected, if not than it won't be. Best greetings, Paweł Wielgus. 2009/5/26 Bas Schulte ba...@connectedcreations.nl: Hi, I'm pretty much stumped about this one. I have a list of countries (ListCountry)

How to use 'extends' attribute of form-bean tag as well as action tag

2009-05-26 Thread udaykumar
Hi, I'm using Struts 1.3.10 GA build. I Know that we have feature called 'extends' attribute in form-bean, action and also in form tag of validation.xml file. I'm able to use extends attribute of form in validation.xml file .But now the problem is i'm bit confused how to use the same attribute

Force user to specific page

2009-05-26 Thread Jim Collings
How can I force the user to go to a specific page, if a specific property is set? Jim C. - To unsubscribe, e-mail: user-unsubscr...@struts.apache.org For additional commands, e-mail: user-h...@struts.apache.org

Re: Force user to specific page

2009-05-26 Thread Jim Collings
Server side. Thing is that we have container based security and I just need to check and make sure the userid is set. If it isn't, force the user to the page where that happens. I could write an interceptor but this seems like re-inventing the wheel as it seems like there should be something out

Re: Force user to specific page

2009-05-26 Thread Lukasz Lenart
2009/5/26 Jim Collings jlistn...@gmail.com: I could write an interceptor but this seems like re-inventing the wheel as it seems like there should be something out there that will do this already. Your own Interceptor is the best solution and the second best option is to use Acegi or something

submit s:iterator list

2009-05-26 Thread tutul
Hi, Does anyone knows how I can submit a list back to the action?? I have a ListDemandRequest that I am displaying in the jsp. DemandRequest has Id, status, comments. Some of the fields in it are pre-populated (id) but some of them will be added by the user (comment, status). I have it send it

RE: Struts 2 dispatcher does not see namespace and action in URL

2009-05-26 Thread Mitchell, Steven
I found a post about setting com.ibm.ws.webcontainer.invokefilterscompatibility = true, but it made no difference. The namespace and action name are still getting dropped before reaching Struts. Since it works find on Tomcat 5.5, I suspect com.ibm.ws.webcontainer.filter.FilterInstanceWrapper,

Re: Force user to specific page

2009-05-26 Thread Lukasz Lenart
2009/5/26 Jim Collings jlistn...@gmail.com: How can I force the user to go to a specific page, if a specific property is set? With JavaScript? Or if you mean server side solution, in execute() method return different result namr base on that property which is defined as a redirect to page you

Jsp's java variable access from Strtus tag block

2009-05-26 Thread Qunhuan Mei
Hi, Sorry for my ignorance but could some one tell me how to access java variable within jsp from struts tag blocks. See the sample code below (say, from test.jsp) ... % boolean goAhead = true; int counter = 0; % s:if test=goAhead ... !-- go a head and do

Re: submit s:iterator list

2009-05-26 Thread Luis Medina
Use a s:textarea tag insted of an html input s:textarea name=demandRequest[%{#stat.index}].comments value=%{comments} / On Tue, May 26, 2009 at 11:01 AM, tutul shubhrakarma...@hotmail.com wrote: Hi, Does anyone knows how I can submit a list back to the action?? I have a ListDemandRequest

RE: submit s:iterator list

2009-05-26 Thread Martin Gainty
MGclosest example i could find is located at https://svn.apache.org/repos/asf/struts/struts2/branches/STRUTS_2_0_X/apps/showcase/src/main/webapp/conversion/enterAddressInfo.jsp MGcheck these comments Martin __ Verzicht und

Re: Jsp's java variable access from Strtus tag block

2009-05-26 Thread Chris Pratt
I would look into the s:set tag. It should do the trick. (*Chris*) On Tue, May 26, 2009 at 9:47 AM, Qunhuan Mei q...@qm18.wanadoo.co.uk wrote: Hi, Sorry for my ignorance but could some one tell me how to access java variable within jsp from struts tag blocks. See the sample code below

Re: s:select list and pre-selected item

2009-05-26 Thread Bas Schulte
We ran into an issue that will be fixed in 2.1.7: https://issues.apache.org/struts/browse/WW-3140?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=46241 #action_46241 We worked around it by not using s:select but coding a select using s:iterator (the

RE: Struts 2 dispatcher does not see namespace and action in URL

2009-05-26 Thread Struts Two
Do you have Basic or Form based authentication enabled in your web.xml? --- On Tue, 5/26/09, Mitchell, Steven steven.mitch...@umb.com wrote: From: Mitchell, Steven steven.mitch...@umb.com Subject: RE: Struts 2 dispatcher does not see namespace and action in URL To: Struts Users Mailing List

Re: RequiredString Validation doesn't work and AbstractValidationActionSupport is missing?

2009-05-26 Thread Niklas Johansson
This ain't going to well, I am sorry for taking your time! However, I must be close to the solution since I found an example on Internet which I managed to get to work, more or less like I want it to work. But when going back to my own code, it still doesn't work, even though I tried to do

The path of an ForwardConfig cannot be null

2009-05-26 Thread RameshKesavanarayanan
Hi all, I have page1.jsp . The action of this is per my struts-config is as follows action path=/submitBranchingProfile name=BranchingProfileForm type=com.pearson.cat.action.testsetup.branchingprofile.BranchingProfileAction scope=request parameter=submitprofile validate=true forward name=success

RE: Struts 2 dispatcher does not see namespace and action in URL

2009-05-26 Thread Mitchell, Steven
To answer your question, the application is using form based authentication. login-config auth-methodFORM/auth-method realm-nameSecurity Profile/realm-name form-login-config form-login-page/[my path]/[my login].jsp/form-login-page

Re: submit s:iterator list

2009-05-26 Thread Dave Newton
tutul wrote: Does anyone knows how I can submit a list back to the action?? What happens when you run the code? Is it a typo that the setter is missing the opening paren for the parameters? Just glancing at it it seems like it should work. Oh, wait. Did you check the rendered HTML to see

Re: Jsp's java variable access from Strtus tag block

2009-05-26 Thread Dave Newton
Qunhuan Mei wrote: Sorry for my ignorance but could some one tell me how to access java variable within jsp from struts tag blocks. See the sample code below (say, from test.jsp) ... % boolean goAhead = true; int counter = 0; % s:if test=goAhead ... !--

Re: Struts 2 dispatcher does not see namespace and action in URL

2009-05-26 Thread Dave Newton
Martin Gainty wrote: did ibm provide any solution to these problems with their AppServer? http://www.networkworld.com/news/2009/032609-ibm-layoffs.html Huh? steven.mitch...@umb.com wrote: I have a Struts 2 application that runs fine under Tomcat 5.5 that will not run on a fully patched