Re: retrieving data from form that has unknown (changing) number of fields

2009-05-20 Thread Wes Wannemacher
On Wednesday 20 May 2009 11:25:50 pm Bhaarat Sharma wrote: > hi > > I have a form that will have varying number of fields inside it. The > number of fields is generated dynamically and is not always the same. When > I am submitting this form to my action class, is there a way to get all the > fie

retrieving data from form that has unknown (changing) number of fields

2009-05-20 Thread Bhaarat Sharma
hi I have a form that will have varying number of fields inside it. The number of fields is generated dynamically and is not always the same. When I am submitting this form to my action class, is there a way to get all the fields back in a systematic manner? Does struts2 provide any mechanism t

Re: IllegalStateException: Cannot forward. Response already committed.

2009-05-20 Thread Dale Newfield
Sorry to hijack this thread, but it looks like Wes has already given you a pretty complete answer. At first I thought you were going to be asking about this: http://wiki.glassfish.java.net/Wiki.jsp?page=FaqWebAppUnableToSetRequestCharEncoding I get a warning in my glassfish logs for pretty much

Re: IllegalStateException: Cannot forward. Response already committed.

2009-05-20 Thread Wes Wannemacher
The JSP compiler simple turns those <% %> tags inside out and everything outside of those tags is a string with an out.print... In your case, the first two things in the file generate returns... Whitespace is significant... Let me see if I can make it visually more understandable Index.jsp <%@ tag

IllegalStateException: Cannot forward. Response already committed.

2009-05-20 Thread Hermann X Lau
Thanks in advance for any help on this... I understand we get this exception when the JSP attempts to write to the print stream after the response has been committed but I don't see how this is occurring in my situation since my JSP just contains a simple forward. Index.jsp <%@ taglib uri="ht

RE: struts2 on jboss java.lang.NoClassDefFoundError: org/apache/struts2/util/ObjectFactoryDestroyable

2009-05-20 Thread Jon Pearson
java2ParentDelegation=false > > > > > > > > > > > > > > > > > > serv/ServPianificazioneContrattiBeanLocal > > > > > > Accoglienza/ServPianificazioneContrattiBean/l > > > ocal >

RE: struts2 on jboss java.lang.NoClassDefFoundError: org/apache/struts2/util/ObjectFactoryDestroyable

2009-05-20 Thread Jon Pearson
gt; >/chapterEight/Error.jsp > > > > > > > > > result="error"/> > > > > > > > class="pianificazioneWeb.action.PianificazioneContratto"> >

RE: struts2 on jboss java.lang.NoClassDefFoundError: org/apache/struts2/util/ObjectFactoryDestroyable

2009-05-20 Thread Jon Pearson
icazioneWeb.action.DatiContratto"> > tiles.Contratto > > > > class="pianificazioneWeb.action.DatiOpportunita"> > tiles.Opportunita > > > > class="pianificazioneW

Re: Accessing protected resources via a login page

2009-05-20 Thread Stuart Ellidge
Hi Steve, Glad to hear you got it working - just as an observation (and I really haven't tested this to check, so it is a question), but would HttpServletRequest.getQueryString() not have provided you with the original parameters? So a combination of both getRequestURL and getQueryString could

Re:RE: Struts2+ReST-plugin prolems need help!!!

2009-05-20 Thread xnpeng
Hi Martin, don't know howto do it. can you please give me some detailed materials? 在2009-05-20,"Martin Gainty" 写道: > >let the StrutsDispatcher handle the navigation details >you'll have to fill in any necessary java classes as well as input/output jsps >but the basic structure is outlined

RE: Accessing protected resources via a login page

2009-05-20 Thread Steve
Thanks to Stuart, Lukasz and Wes for your advice. I decided to stick with a home-grown solution because I'm only interested in GET's right now and I don't want the complexity of adding Spring into the mix with EJB3, Struts and JPA already working well together. This is because I haven't used Sprin

Re: problems upgrading from struts 2.0 to 2.1

2009-05-20 Thread Musachy Barroso
are you using the REST plugin? I can't think of anything else that would add that ".xhtml" extension. musachy On Wed, May 20, 2009 at 11:48 AM, akoo wrote: > > Hi guys, > I am having some strange issues trying to upgrade from struts 2.0 to 2.1. > I have this simple login form > > > > >  Simple

problems upgrading from struts 2.0 to 2.1

2009-05-20 Thread akoo
Hi guys, I am having some strange issues trying to upgrade from struts 2.0 to 2.1. I have this simple login form Simple jsp page Username Password

Re: Multiple set of templates

2009-05-20 Thread Germán Castro
Hi, I found this or Is it posible do the same but with java code in a filter or controller? Thanks Germán On Fri, May 15, 2009 at 5:15 PM, Germán Castro wrote: > Hi, > > I'm new in struts and i'm searching if I can do something that i need using > struts 2. > > The situation is that

Re: struts2 on jboss java.lang.NoClassDefFoundError: org/apache/struts2/util/ObjectFactoryDestroyable

2009-05-20 Thread Daniele Del Gaudio
>/action/PianificazioneContratto.action class="pianificazioneWeb.action.InsPianificPM"> tiles.InsPianificPM Thanks, daniele __ Information from ESET NOD32 Antivirus, version of viru

RE: struts2 on jboss java.lang.NoClassDefFoundError: org/apache/struts2/util/ObjectFactoryDestroyable

2009-05-20 Thread Martin Gainty
> > > class="pianificazioneWeb.action.DatiOpportunita"> > tiles.Opportunita > > > > class="pianificazioneWeb.action.DatiProgetto"> > > n

Re: Block accessing in some path with filter.

2009-05-20 Thread Andy Sykes
You need to include elements in your filter mappings for the Struts filter. eg. struts2 /* REQUEST FORWARD With no element specified, the container assumes you mean the filter chain only gets applied to requests. The FORWARD element means the filter cha

RE: Struts2+ReST-plugin prolems need help!!!

2009-05-20 Thread Martin Gainty
let the StrutsDispatcher handle the navigation details you'll have to fill in any necessary java classes as well as input/output jsps but the basic structure is outlined in struts.xml illustrated below Martin Gainty __ Verzicht und Vertraulichkeitanm

struts2 on jboss java.lang.NoClassDefFoundError: org/apache/struts2/util/ObjectFactoryDestroyable

2009-05-20 Thread Daniele Del Gaudio
class="pianificazioneWeb.action.InsPianificPM"> tiles.InsPianificPM Thanks, daniele __ Information from ESET NOD32 Antivirus, version of virus signature database 4090 (20090520) __ The message was checked b

Re: Block accessing in some path with filter.

2009-05-20 Thread Stefano Tranquillini
now is taked. but i've some problem with the dispacer. i've an action mapped in this way: denied namespace is / if i manually put in this url: http://localhost:8080//WAP-Shop-war/denied.action its WORKS. the filter, else branch is this: else { RequestDisp

RE: JSON plugin class loading problem? (Part Deux)

2009-05-20 Thread Martin Gainty
he must be passing in JSONResult in one of the params to Action can we see web.xml struts.xml and struts-default.xml and struts-config.xml please display ALL xml files for your project thanks, Martin Gainty __ Jogi és Bizalmassági kinyilatkoztatás/Ver

Re: Block accessing in some path with filter.

2009-05-20 Thread Andy Sykes
Put the mapping for the admin filter above the struts2 filter. Filters are invoked in the order in web.xml, first to last. The struts filter is catching the request first and dispatching it before it ever reaches the admin filter. On 20 May 2009, at 09:37, Stefano Tranquillini wrote: Hi a

Re:Re: Struts2+ReST-plugin prolems need help!!!

2009-05-20 Thread xnpeng
Hi Dave! I'm using Struts2.1.6 and struts2-rest-plugin-2.1.6. first ,I need a global error page when exception happen like this: Stacktraces java.lang.NoSuchMethodException: com.xunan.sitexa.rest.MainController.a() java.lang.Class.getMethod(Unknown Source) org.apache.struts2.interce

Re: customize fielderror

2009-05-20 Thread Dave Newton
manub wrote: Yes. renders also and tag, and I don't need them. I'm in need of a way to showing only the errors for a specific field without having any HTML tag (I need only the plain text). You'd either need to create/extend/modify the theme, use CSS, or just do it manually. Dave ---

Block accessing in some path with filter.

2009-05-20 Thread Stefano Tranquillini
Hi all. i need to block the path /admin/ for all the pepole. only the people logged in as root can access it. i've done a filter, but struts seems to dosen't works with its struts2 org.apache.struts2.dispatcher.FilterDispatcher adminFilter filter.Admi

Re: upload and store img

2009-05-20 Thread Stefano Tranquillini
hi, i've tried with db but is complex, i've do in this way: using the inteceptior of struts and the tag wrote: > > Struts FileUploadInterceptor offers maximumSize,allowedTypes and > allowedExtensions parameters specifically > > Interceptor parameters: > > > > > > > > > maximumSize (optional) - th

RE: Any validation flag available to the action code?

2009-05-20 Thread Qunhuan Mei
Lukasz, Thanks for your reply. I left some code in action code constructor by mistake. Sorry for causing the confusion. Have a nice day! Qunhuan -Original Message- From: Lukasz Lenart [mailto:lukasz.len...@googlemail.com] Sent: 2009年5月20日 7:55 To: Struts Users Mailing List Subject: Re: A

Re: passing form parameters to a custom validator

2009-05-20 Thread Lukasz Lenart
2009/5/20 manub : > I've written a custom field validator, which needs other field values to > validate his field. I need a way to pass that values to that field > validator. Did you try to use param tag as below? $...@pl.org.lenart.ems.model.employeetype@.value() != 'dd'} error.emplo

Re: passing form parameters to a custom validator

2009-05-20 Thread manub
Lukasz Lenart wrote: > > Frankly, I don't understand, are you trying to pass data from > validator xml configuration to action? > I've written a custom field validator, which needs other field values to validate his field. I need a way to pass that values to that field validator. -- View thi

Re: Problem with xwork convertor

2009-05-20 Thread Ikya Technical
Thanks. It worked. Regards, Sreekanth On Wed, May 20, 2009 at 11:22 AM, Wes Wannemacher wrote: > It might be easier to grab the most recent snapshot builds from here - > > http://people.apache.org/builds/struts/nightlies/2.x/ > > Give them a try, they should include all of the appropriate depen

Re: passing form parameters to a custom validator

2009-05-20 Thread Lukasz Lenart
2009/5/20 manub : > Yes, I did. But in the action the string takes the value "${field}" and not > the field value. Frankly, I don't understand, are you trying to pass data from validator xml configuration to action? Regards -- Lukasz http://www.lenart.org.pl/ --

Re: passing form parameters to a custom validator

2009-05-20 Thread manub
Yes, I did. But in the action the string takes the value "${field}" and not the field value. Lukasz Lenart wrote: > > 2009/5/19 manub : >> I'm trying to write a custom field validator which needs other fields to >> validate the field I need to validate. How can I pass field values (and >> not >

Re: passing form parameters to a custom validator

2009-05-20 Thread Lukasz Lenart
2009/5/19 manub : > I'm trying to write a custom field validator which needs other fields to > validate the field I need to validate. How can I pass field values (and not > static params) to a field validator in the validation xml? I'm using Struts > 2.1.6. Did you try ${fieldFromAction} ? Regar

Re: customize fielderror

2009-05-20 Thread manub
Yes. renders also and tag, and I don't need them. I'm in need of a way to showing only the errors for a specific field without having any HTML tag (I need only the plain text). newton.dave wrote: > > manub wrote: >> I used the iterator trick described before and it works, showing me all >> f