pls help:

2008-01-14 Thread john lee
if i specify the following ActionErrors errors; errors.add("Example", new ActionMessage("error.example")); saveErrors(request.errors); then i can display the "Example" at the .jsp by My puzzle is that i have an the folowing at struts-config.xml

Re: Struts 2 and Container resources

2008-01-14 Thread Don Brown
Do you want a bean from the Container? If so, just put an @Inject annotation above a setter. For example, to get the ObjectFactory, put this code in your Action: @Inject public void setObjectFactory(ObjectFactory factory) { this.objectFactory = factory; } Since Actions, Results, and Intercept

Re: Struts 2 and Container resources

2008-01-14 Thread Ted Husted
The container's resources can be access from an Action via the HttpServletRequest object. To obtain the HttpServletRequest object, see * http://struts.apache.org/2.x/docs/how-can-we-access-the-httpservletrequest.html HTH, Ted * On Jan 10, 2008 5:55 PM, Filipe

OGNL makeNew

2008-01-14 Thread jimski
In the type conversion page on the wiki there's some discussion of automagically creating new elements in a set. I've been trying to get this to work but haven't succeeded thus far. Can anyone point me to a working example of the collection.makeNew[index].property feature? Unlike Map and List e

Spring Webflow Plugin to Struts 2

2008-01-14 Thread Cheng Wei Lee
Hi all, I was trying out the SWF plugin from Google codes with the old example and encountered some exceptions. Got the example from https://issues.apache.org/struts/browse/WW-1525. When I tried to enter the age, I got the following exception. I'd changed the example.xml slightly to use the: com

Re: [S2] Best approach to separate look & feel with same backend code

2008-01-14 Thread Jeromy Evans
Hi Neil, The approach I use is to implement org.apache.tiles.definition.DefinitionsFactory and instruct Tiles to use your DefinitionsFactory web.xml: org.apache.tiles.definition.DefinitionsFactory myDefinitionsFactoryImpl The custom DefinitionsFactory implementation receives requests fo

struts2: how to return an validate-error if user entered incorrect email format?

2008-01-14 Thread xianwinwin
I would like to validate if the user has entered a valid email. for this I have the method @TypeConversion(converter = "com.utilities.conversion.EmailTypeConversion") public void setEmail(String email) { this.email = email; } the conversion (where I'm a

Re: Feedback: WW-2414, XSS attack is possible if using and

2008-01-14 Thread Jeromy Evans
Antonio Petrelli wrote: 2008/1/14, GF <[EMAIL PROTECTED]>: I think that there are 2 issues. Both important. One in s:url and the other in s:a s:url generates a URL that can contain a malicious query string (it doesn't encode anything except what is passed with s:param). And this is not good,

Re: s2 : checkbox and checkboxlist : dynamic lists

2008-01-14 Thread Rubbinio
Struts 2.0.11 Nope, no documentation just many attempts until we got it to work. The class looks like this: public class OurAction extends ActionSupport implements SessionAware, ParameterAware, ParameterNameAware { . private String[] selectedGroup; . public void setSelectedGroup(String[

Re: S2 Spring Bean DI to an i18n ListResourceBundle

2008-01-14 Thread ARCS
Simple solution. Also noted that the bundle only gets loaded once and everything seems to work fine. Spring rocks. String[] config= new String[]{"applicationContext-resources.xml", "applicationContext-dao.xml", "applicationContext-service.xml"}; ApplicationContext context = new ClassPathXmlAp

Re: s2 : checkbox and checkboxlist : dynamic lists

2008-01-14 Thread hernan gonzalez
Does not work for me. Does that work on struts 2.0.x ? Did you find documented somewhere ? Some special interceptor o configuration ? Hernán J. González On Jan 11, 2008 4:23 PM, Rubbinio <[EMAIL PROTECTED]> wrote: > > Actually you can do something like this > > > > And in the action class you ca

Re: Wrong struts rendered tags

2008-01-14 Thread Mitchell James
Look at setting xhtml theme. http://struts.apache.org/2.0.11/docs/themes-and-templates.html -- James Mitchell On Jan 14, 2008, at 1:20 PM, Schuenck wrote: Hi, I'm starting in Struts and already found a little problem. While rendering the html inputs, struts don't close the t

Wrong struts rendered tags

2008-01-14 Thread Schuenck
Hi, I'm starting in Struts and already found a little problem. While rendering the html inputs, struts don't close the tags. For example: The tag renders: Instead of: The tag wasn't closed and the document can't be validated as XHTML. I've tried to use the and but the return was the sam

RE: [S2] Best approach to separate look & feel with same backend code

2008-01-14 Thread Neil Aggarwal
Scott: Great! I will use tiles. I am confused about know to know which set of tiles to load. The sites will have different domain names. Can I tell tiles to use a set based on that? Thanks, Neil -- Neil Aggarwal, (832)245-7314, www.JAMMConsulting.com Eliminate junk email and reclaim y

Re: [OT: DOJO] Dojo dragndrop

2008-01-14 Thread Dave Newton
Did you try the Dojo forums? d. --- Pablo Vázquez Blázquez <[EMAIL PROTECTED]> wrote: > Hi! > > I know it has nothing to do with Strtus2, but I didn´t find any place > where to see a solution for my problem, so... apologize for this post. I > know it is not the place. > > I´m using dojo libr

[OT: DOJO] Dojo dragndrop

2008-01-14 Thread Pablo Vázquez Blázquez
Hi! I know it has nothing to do with Strtus2, but I didn´t find any place where to see a solution for my problem, so... apologize for this post. I know it is not the place. I´m using dojo library that comes with Struts 2.0.9. Well, I would like to know if sbd has ever successfully used the D

Re: Struts 2.1.0

2008-01-14 Thread Piero Sartini
Am Montag, 14. Januar 2008 17:37:19 schrieb Frans Thamura: > hi there > > i just testing struts2 2.1.0, > > can help me how to test the REST plugins, > > am i have to get from SVN or can use this? > > i know that 2.1.0 is the pre relase for 2.1.1 If you are using maven, just include the following

Re: Get the plugins

2008-01-14 Thread Piero Sartini
Am Montag, 14. Januar 2008 17:41:06 schrieb Frans Thamura: > hi there > > where is the place so i can download the codebehind plugins? If you just start, I would suggest trying the new convention plugin. You can find it here: http://svn.apache.org/repos/asf/struts/sandbox/trunk/struts2-conventio

Get the plugins

2008-01-14 Thread Frans Thamura
hi there where is the place so i can download the codebehind plugins? -- Frans Thamura

Struts 2.1.0

2008-01-14 Thread Frans Thamura
hi there i just testing struts2 2.1.0, can help me how to test the REST plugins, am i have to get from SVN or can use this? i know that 2.1.0 is the pre relase for 2.1.1 -- Frans Thamura

Re: Feedback: WW-2414, XSS attack is possible if using and

2008-01-14 Thread Antonio Petrelli
Fabio, I sent a mail to the Struts Developers mailing list about the problem you reported, please follow the discussion there. Thanks Antonio 2008/1/14, Antonio Petrelli <[EMAIL PROTECTED]>: > > 2008/1/14, GF <[EMAIL PROTECTED]>: > > > > > > > > Sorry again Fabio, but I need to understand: the qu

Re: Feedback: WW-2414, XSS attack is possible if using and

2008-01-14 Thread Antonio Petrelli
2008/1/14, GF <[EMAIL PROTECTED]>: > > > > > Sorry again Fabio, but I need to understand: the querystring does not > seem > > to have a "param=value" structure, and has "test" as action, and > > does not take any dynamic value (i.e. parameter), but maybe I am missing > > something. > > The bug is

Re: Feedback: WW-2414, XSS attack is possible if using and

2008-01-14 Thread GF
> > Sorry again Fabio, but I need to understand: the querystring does not seem > to have a "param=value" structure, and has "test" as action, and > does not take any dynamic value (i.e. parameter), but maybe I am missing > something. The bug is calling that page itself (I mean XSS.jsp) passing vi

Re: Feedback: WW-2414, XSS attack is possible if using and

2008-01-14 Thread Antonio Petrelli
2008/1/14, GF <[EMAIL PROTECTED]>: > > > Fabio, one little question. > > I don't see how this code can write the parameter passed to the JSP > > page. Probably you pasted the wrong code in the part. > > Just add (i.e. in IE6) after the ? the following query string: > >'">alert('helloworld') Sorr

Re: (Struts2) howto access the user.fname on the jsp page (user's object in http session)

2008-01-14 Thread xianwinwin
THANK YOU ROBI Roberto Nunnari wrote: > > Try this: > > > > -- > Robi > > > xianwinwin wrote: >> Hi there, >> >> using struts2: I have just place the user's information on a session: >> >> session.setAttribute(Properties.USER_HANDLE, secUser); >> >> >> I wonder how to access on a

Re: Feedback: WW-2414, XSS attack is possible if using and

2008-01-14 Thread GF
> Fabio, one little question. > I don't see how this code can write the parameter passed to the JSP > page. Probably you pasted the wrong code in the part. Just add (i.e. in IE6) after the ? the following query string: >'">alert('helloworld')

Re: Feedback: WW-2414, XSS attack is possible if using and

2008-01-14 Thread Antonio Petrelli
2008/1/12, GF <[EMAIL PROTECTED]>: > > XSS Test > ... > http://localhost:8080/struts2-blank-2.0.11/example/XSS.jsp? > >'">alert(document.cookie) Fabio, one little question. I don't see how this code can write the parameter passed to the JSP page. Probably you pasted the wrong code in the part.

Re: (Struts2) howto access the user.fname on the jsp page (user's object in http session)

2008-01-14 Thread Roberto Nunnari
Try this: -- Robi xianwinwin wrote: Hi there, using struts2: I have just place the user's information on a session: session.setAttribute(Properties.USER_HANDLE, secUser); I wonder how to access on a jsp page the info; I tried, unsuccessfully, the following combinations: any idea?

(Struts2) howto access the user.fname on the jsp page (user's object in http session)

2008-01-14 Thread xianwinwin
Hi there, using struts2: I have just place the user's information on a session: session.setAttribute(Properties.USER_HANDLE, secUser); I wonder how to access on a jsp page the info; I tried, unsuccessfully, the following combinations: any idea? -- View this message in context: http://w

AW: struts 2.0.11: autocompleter and notify-/listenTopics

2008-01-14 Thread Otto, Frank
I have found the solution: 'notifyTopics' comma separated list of topics names, that will be published. Three parameters are passed: * data: selected value when type='valuechanged' * type: 'before' before the request is made, 'valuechanged' when selection changes, 'load' when the r

Re: Feedback: WW-2414, XSS attack is possible if using and

2008-01-14 Thread GF
> I think that there are two levels of encoding: > > 1) in s:url, the parameters values must be encoded, to create a valid > (and safe) URL. > 2) in s:a, the whole URL must be encoded, simply because it is used > inside an HTML element () between double quotes. For example, '&' > becomes & So do y

Re: Feedback: WW-2414, XSS attack is possible if using and

2008-01-14 Thread Antonio Petrelli
2008/1/14, GF <[EMAIL PROTECTED]>: > I think that there are 2 issues. Both important. One in s:url and the > other in s:a > > s:url generates a URL that can contain a malicious query string (it > doesn't encode anything except what is passed with s:param). And this > is not good, mainly because whe

Re: Feedback: WW-2414, XSS attack is possible if using and

2008-01-14 Thread GF
> It is a bug, since ganfab (sorry I cannot read your name :-) ) tried I'm Fabio Gandola. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: Feedback: WW-2414, XSS attack is possible if using and

2008-01-14 Thread GF
I'm trying to understand where the real problem is. I think that there are 2 issues. Both important. One in s:url and the other in s:a s:url generates a URL that can contain a malicious query string (it doesn't encode anything except what is passed with s:param). And this is not good, mainly beca

Re: Secure ajax call using prototype to a struts action ....

2008-01-14 Thread Mufaddal Khumri
The URL is working fine without ajax. Yes standard port 443. The issue i think is making a https ajax request from a http page. I will check that plugin out. -Mufaddal. On Jan 12, 2008, at 2:16 AM, nuwan chandrasoma wrote: Hi, what is the port number you have configured to run SSL in your

struts 2.0.11: autocompleter and notify-/listenTopics

2008-01-14 Thread Otto, Frank
Hi, I have 6 autocompleter combo boxes. The first refresh the second, the second the third and so one. I use notifyTopics and listenTopics: My problem is, that the topics were called more than one time, If I will select a value from the first combo box. This is to many overhead. T

Re: JSP syntax errors through icnlude

2008-01-14 Thread Al Sutton
Just re-read your original message. So you have tried it on an app server and everything is OK. Doesn't that indicate the problem lies with eclipse and not struts?, shouldn't it be the Eclipse bug tracking system you put your report in and not Struts Jira? - Original Message - From: "

Re: JSP syntax errors through icnlude

2008-01-14 Thread Al Sutton
First question; Why do you think this is a Struts bug? I encountered the same problem when I upgraded from Eclipse 3.2 to 3.3 without changing the project. Have you tried downgrading your version of Eclipse to see if that resolves the problem?, have you also tried compiling and testing the pr

Re: Wildcard mappings/templates need to refer to a package name

2008-01-14 Thread Ted Husted
I think you make a good case. The best thing might be to file with XWork, since I believe that's where the code would need to be changed. * http://jira.opensymphony.com/secure/Dashboard.jspa If you had a time to review the code and suggest a patch, all the better. HTH, Ted

Re: [S2] Best approach to separate look & feel with same backend code

2008-01-14 Thread stanlick
Then I would suggest Tiles. This would be as easy as getting wet in a pond. Scott On Jan 13, 2008 9:01 PM, Neil Aggarwal <[EMAIL PROTECTED]> wrote: > Rod: > > The functionality will be exactly the same for > each site. > > How do I tell struts to load a given set of > tiles based on the domain

JSP syntax errors through icnlude

2008-01-14 Thread Maxx
Hello! Before issuing a bug report on Struts' bug tracker, I'd like to have your advices about a rather stranger syntax error I'm getting with Eclipse (v.3.3/Europa) and JSP using Struts2 tags. Here's own I can reproduce it: Create the project: New Project > Other... > Web > Dynamic Web Project

Create DateTimePicker

2008-01-14 Thread Shoaib Gauhar
Hello, I am using Display Tags in my JSP. I have used a customized TableDecorator to render TextFields and ComboBoxes in its columns. Now i want to render a DateTimePicker in one of its columns. As i understand, the display tag does not render Struts Tags when outputted through TableDecorator b

[S2]method not called

2008-01-14 Thread carmi_cd
hi i have a table that has a checkbox, details of the record such as lastname, firstname with it. when user selects a record or records using checkbox corresponding to it, and click the delete button the record or records selected should be deleted. My problem is it is not able to execute the dele