Re: how to re-init / update parameter of an interceptor during runtime?

2009-04-02 Thread Joe Lam
thx for your reply. actually I am not going to change the param regularly. this is more like "just in case I want to change the setting in the future". thx Joe Nils-Helge Garli wrote: > > Why do you need to do that? > > Nils-H > > On Fri, Apr 3, 2009 at 5:05

how to re-init / update parameter of an interceptor during runtime?

2009-04-02 Thread Joe Lam
I got this in action mapping value01 that parameter actually is an instance property of that interceptor instance. private String param01; public void setParam01(String value){ param01= value; } I wonder if it is possible to call again the setter method via API during runtime

[S2] error 404 + sitemesh template

2007-11-22 Thread Joe Lam
I set this in web.xml 404 /error404.jsp but the output doesnt come with the site template (using sitemesh) anyone know why and how to solve this?? btw, any chance to make error 404 to call an action ? like 404 /custom.action seems tomcat on

[S2] regarding "struts.configuration.xml.reload" setting in struts.xml

2007-09-09 Thread Joe Lam
I have this in struts.xml and I have this constant injected to my class does this mean that whenever I change my constant's value in struts.xml, my class will get the updated value? by doing a simple test, I can't get it updated. If yes, what am I missing? If no, how to reload struts.xml conf

Re: [S2] File Download Example in showcase doesn't work with contentType application/x-download using IE

2007-08-30 Thread Joe Lam
; something useful. > > The exception you quoted is unrelated and caused because you're writing > to the output stream within a JSP that's already doing so. That code is > better suited to its own servlet. > > Hope that helps, > regards, > Jeromy Evans > > J

[S2] File Download Example in showcase doesn't work with contentType application/x-download using IE

2007-08-30 Thread Joe Lam
try to make a file download action without opening the file. I try the showcase file download example. change contentType to application/x-download in struts.xml application/x-download with firefox it works fine. with IE, it still open the gif in browser. anyon

Re: [S2] how to get the constants in struts.xml programmatically?

2007-08-22 Thread Joe Lam
Anyone know the answer? Thank you very much Joe Lam wrote: > > In my class, I want to read a constant in struts.xml. > I see some examples using @inject , somehow I cant make it work. > > May someone help me? just wanna to get those constants in struts.xml > (don&

[S2] how to get the constants in struts.xml programmatically?

2007-08-17 Thread Joe Lam
In my class, I want to read a constant in struts.xml. I see some examples using @inject , somehow I cant make it work. May someone help me? just wanna to get those constants in struts.xml (don't want to use java properties file this time. I think it is easier to maintain in struts.xml) Thanks

[s2] what is your practice to do Sidebar thing??

2007-08-13 Thread Joe Lam
May I know what is your practice to do Sidebar thing? here the sidebar means a block lets say on the left side showing login form for guest user and showing user menu for logged in user. ? ? or do it in decorator level (sitemesh) ? thank you very much. Joe -- View this message in context: h

Re: Is it possible to pass a dynamic parameter to a redirectAction?

2007-08-05 Thread Joe Lam
This might help http://www.vitarara.org/cms/struts_2_cookbook/post_and_redirect http://www.vitarara.org/cms/struts_2_cookbook/post_and_redirect Piero Sartini-3 wrote: > > I have the following situation: > a searchfield is on top of a table presenting results. if there is only > one > result

[S2] How to avoid FileUploadInterceptor to save the tmp file?

2007-07-30 Thread Joe Lam
Hi all, I wonder how to avoid FileUploadInterceptor to save the tmp file. because in my action I will process it anyway. IMO it is not efficient to have the interceptor to save a tmp file first and then have my action class to process the tmp file after. I think the most efficient way is to get