Re: Struts 2 and Spring AOP using ProxyFactoryBean
This is a bug I just fixed in xwork 1.2.x and xwork 2.0.x. See http://jira.opensymphony.com/browse/XW-465 for details. Tom Shih Lee wrote: Hello, I have downloaded struts-blank to play around. I was trying to use Spring AOP with Struts 2. However, I am getting the following error: 2007-02-04 21:27:17,233 DEBUG AbstractBeanFactory - Bean with name 'helloWorld' is a factory bean java.lang.IllegalArgumentException: object is not an instance of declaring class at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:287) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:181) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:148) at advice.TimeLoggingInterceptor.invoke(TimeLoggingInterceptor.java:31) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176) at com.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActionInvocation.java:354) at com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultActionInvocation.java:228) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:202) at com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:177) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:86) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:115) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:86) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(ConversionErrorInterceptor.java:123) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.ParametersInterceptor.intercept(ParametersInterceptor.java:147) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:105) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:80) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:204) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept(ModelDrivenInterceptor.java:74) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept(ScopedModelDrivenInterceptor.java:120) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at org.apache.struts2.interceptor.ProfilingActivationInterceptor.intercept(ProfilingActivationInterceptor.java:59) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept(DebuggingInterceptor.java:174) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept(ChainingInterceptor.java:115) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.I18nInterceptor.intercept(I18nInterceptor.java:143) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.PrepareInterceptor.intercept(PrepareInterceptor.java:115) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at org.apache.struts2.interceptor.Servlet
Re: [s2] Autopopupation of fields fails with "enctype="multipart/form-data" in form
Thanks Dariusz, Adding the filter fixed the issue. Z - Original Message From: Dariusz Wojtas <[EMAIL PROTECTED]> To: Struts Users Mailing List Sent: Sunday, February 4, 2007 1:20:02 PM Subject: Re: [s2] Autopopupation of fields fails with "enctype="multipart/form-data" in form Hi Zafer, I would: 1) check the archives of this mailing list from the last 2 weeks, there was a thread about fileupload issues (parameters are not always set from such form). One of the hints was to use some magical filter in front of the application. It is supposed to clear sth. 2) check if you have any custom filter in front of your action - the multipart parser requires a 'virgin' request object, without accessing any params in it prior to multiparse analysis. If you try to operate on the request earlier - multiparser is not able to finish his task. regards Dariusz Wojtas On 2/4/07, zafer Mohamed <[EMAIL PROTECTED]> wrote: > I have a form with the enctype set to "enctype="multipart/form-data" as I am > uploading a file, the form also contains some other fields. On submission the > autopopulation of other fields fails, but it works correctly if I remove the > enctype="multipart/form-data". Any idea..? > > Thanks > Zafer - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] Need Mail bonding? Go to the Yahoo! Mail Q&A for great tips from Yahoo! Answers users. http://answers.yahoo.com/dir/?link=list&sid=396546091
Re: Struts 2 and Spring AOP using ProxyFactoryBean
--- Shih Lee <[EMAIL PROTECTED]> wrote: > [Spring AOP/S2] Just out of curiosity, does it work if instead of proxying the interface you proxy the class instead, like so: true timeLoggingAdvisor I haven't tried AOPing an Action interface yet, but I can successfully wrap up if I'm doing the class proxy. YMMV, and I believe my test was not under Spring 2 (have not upgraded that app yet). Dave Be a PS3 game guru. Get your game face on with the latest PS3 news and previews at Yahoo! Games. http://videogames.yahoo.com/platform?platform=120121 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Struts 2 and Spring AOP using ProxyFactoryBean
Hello, I have downloaded struts-blank to play around. I was trying to use Spring AOP with Struts 2. However, I am getting the following error: 2007-02-04 21:27:17,233 DEBUG AbstractBeanFactory - Bean with name 'helloWorld' is a factory bean java.lang.IllegalArgumentException: object is not an instance of declaring class at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:287) at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:181) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:148) at advice.TimeLoggingInterceptor.invoke(TimeLoggingInterceptor.java:31) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176) at com.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActionInvocation.java:354) at com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultActionInvocation.java:228) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:202) at com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:177) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:86) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:115) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:86) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.ConversionErrorInterceptor.intercept(ConversionErrorInterceptor.java:123) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.ParametersInterceptor.intercept(ParametersInterceptor.java:147) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.StaticParametersInterceptor.intercept(StaticParametersInterceptor.java:105) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at org.apache.struts2.interceptor.CheckboxInterceptor.intercept(CheckboxInterceptor.java:80) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at org.apache.struts2.interceptor.FileUploadInterceptor.intercept(FileUploadInterceptor.java:204) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.ModelDrivenInterceptor.intercept(ModelDrivenInterceptor.java:74) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.ScopedModelDrivenInterceptor.intercept(ScopedModelDrivenInterceptor.java:120) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at org.apache.struts2.interceptor.ProfilingActivationInterceptor.intercept(ProfilingActivationInterceptor.java:59) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept(DebuggingInterceptor.java:174) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.ChainingInterceptor.intercept(ChainingInterceptor.java:115) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.I18nInterceptor.intercept(I18nInterceptor.java:143) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at com.opensymphony.xwork2.interceptor.PrepareInterceptor.intercept(PrepareInterceptor.java:115) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:200) at org.apache.struts2.interceptor.ServletConfigInterceptor.intercept(ServletConfigInterceptor.java:156) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultAction
Re: Struts-Faces: validator
Kevin-- I would suggest implementing the validation.xml packaged within struts as the basis for your validation efforts Feel free to ping the list if you have any questions HTH, Martin-- --- This e-mail message (including attachments, if any) is intended for the use of the individual or entity to which it is addressed and may contain information that is privileged, proprietary , confidential and exempt from disclosure. If you are not the intended recipient, you are notified that any dissemination, distribution or copying of this communication is strictly prohibited. --- Le présent message électronique (y compris les pièces qui y sont annexées, le cas échéant) s'adresse au destinataire indiqué et peut contenir des renseignements de caractère privé ou confidentiel. Si vous n'êtes pas le destinataire de ce document, nous vous signalons qu'il est strictement interdit de le diffuser, de le distribuer ou de le reproduire. - Original Message - From: "Simons Kevin" <[EMAIL PROTECTED]> To: "Struts Users Mailing List" Sent: Sunday, February 04, 2007 8:46 AM Subject: Re: Struts-Faces: validator > Rodrigo, > > AFAIK that was possible. > > Regards, > - Original Message - > From: "Rodrigo Pereira" <[EMAIL PROTECTED]> > To: "Struts Users Mailing List" > Sent: Saturday, February 03, 2007 10:39 PM > Subject: Struts-Faces: validator > > >> hi All, >> does anybody know if validator work with struts-faces? >> I have read a lot of tutorials on the Internet, but no success at all >> >> >> Thanks, >> Rodrigo Pereira >> >> - >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> >> >> -- >> No virus found in this incoming message. >> Checked by AVG Free Edition. >> Version: 7.5.432 / Virus Database: 268.17.20/664 - Release Date: 2/02/2007 >> 15:42 >> >> > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >
Re: Exceptions design
Hello, it sure is a matter of taste - but I think its not good to use exceptions for this kind of things. After all "User not found" is not an _exception_. Its a well defined case and it happens frequently. (Except you rely on that the user exists, eg. in step 2 of a registration process) I have a rule: If something is defined and I know it will happen often, it should not be an exception. It is a path in the application. Am Sonntag, 4. Februar 2007 18:01 schrieb Francisco Exposito Aguilera: > Hello all, > > I have a doubt about how design the exceptions in my struts project. I have > the action classes and the bean classes. The action classes execute methods > from bean classes, which connect to the database. > > Supposing I am trying to create a user in one of my web pages and the user > I want to create exists. What is the best way to show the user this sql > error? > > 1.Throw the exception in the bean class to the struts ModuleException and > show a typical error page. (I hope this is not the best way because I don´t > like it). > > 2.Before execute the createUser bean method, execute another method to > check if the user already exists. If it exists, use ActionMessages in the > action class to show the error in the same createUser.jsp file. > > That means that if the user doesn´t exist, the action method will access, > at least twice to the database, one for check if the user exists and one > for create it. > > 3.Execute the createUser bean method using try and finally but without > catch; and throw the SQL exception. > > public OTDUser validUser (String dni, String passwd) throws SQLException > { > try > { > Connection to the database and results > } > finally > { > Close resultSet, statement and connection > } > } > > The exception will be catched by the action class, where there is a > catch(SQLException), which will receive the exception from the bean method > > java.sql.SQLException: ORA-1: unique restriction (PK_USER) violated > > And with ActionMessages show it in the same createUser.jsp. But now, can I > know if the SQLException is caused by: > > a) Primary key is violated (java.sql.SQLException: ORA-1: unique > restriction (PK_USER) violated) > > b) Name and both surnames are unique (java.sql.SQLException: ORA-1: > unique restriction (U_NAME_SURNAME1_SURNAME2_U) violated) > > Depending on the exception, I want to show primary key exists or name > and surnames exists with another primary key > > 4.Any suggestion? > > Thanks a lot. > > _ > Horóscopo, tarot, numerología... Escucha lo que te dicen los astros. > http://astrocentro.msn.es/ > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: One tile-conf.xml per namespace
> (BTW, right > now don't matter how I write it tiles configuration is assumed to be > in WEB-INF/tiles.xml, what do I need to put in my web.xml?) Gonçalo, Did you try this: definitions-config /WEB-INF/some-other-filename.xml Regards, Dj. -Original Message- From: Gonçalo Luiz [mailto:[EMAIL PROTECTED] Sent: Saturday, February 03, 2007 7:56 PM To: Dave Newton Cc: Struts Users Mailing List Subject: Re: One tile-conf.xml per namespace Hello Dave, Thank you for your answer. I now I can have multiple files in a comma-separated list (BTW, right now don't matter how I write it tiles configuration is assumed to be in WEB-INF/tiles.xml, what do I need to put in my web.xml?). What I'm trying to achieve is to use the same name for some tiles without getting into an "definition overwrite" problem. As long as the definitions stay in a different Struts Namespace I think there's no problem. However I only know hot to configure a app-wide tiles's configuration (in web.xml) and not a namespace-wide tile's configuration. Is it clear what I'm trying to achieve? Thank you very much. Best Regards, Gonçalo Luiz. On 03/02/07, Dave Newton <[EMAIL PROTECTED]> wrote: > --- Gonçalo Luiz <[EMAIL PROTECTED]> wrote: > > Is it possible to have one tiles configuration file > > per struts namespace ? > > For both S1 and S2 you can configure multiple tiles > config files in a comma-separated list. > > d. > > > > > > Get your own web address. > Have a HUGE year through Yahoo! Small Business. > http://smallbusiness.yahoo.com/domains/?p=BESTDEAL > -- Gonçalo Luiz - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Exceptions design
--- Francisco Exposito Aguilera wrote: > I am doing just now a part for an administrator user > and I want to show the error most clear as possible. Oh, if it's for an admin that would understand and be able to do something, then sure, be as detailed as you want :) > a) I must do an extra request to the database in > order to know if the user exists to show the user the > ActionMessages. Well... you can rely on getting a database constraint violation if you want; I don't know as it *really* matters. I guess I've just always done a lookup first, as (in my mind, anyway) it's not really "exceptional" that someone might choose the same username as somebody else. I tend to view database exceptions as something that shouldn't happen unless something is really *wrong* wrong. There may not be a better reason than preference on this issue :) Seriously, I'm not sure there's any one right way to do this; the declarative exception handling lets the developer decide what exceptions to handle in the framework, or they can be caught earlier and ActionMessages can be used. d. It's here! Your new message! Get new email alerts with the free Yahoo! Toolbar. http://tools.search.yahoo.com/toolbar/features/mail/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [S2] issue
--- Djordje Trifunovic <[EMAIL PROTECTED]> wrote: > However, I never enjoyed having JSP code (including > EL) in my pages, unless absolutely necessary. So > far, I haven't really bumped into anything that > couldn't be solved with S2 tags with some OGNL :) What's the difference? (I mean from a philosophic standpoint :) d. Get your own web address. Have a HUGE year through Yahoo! Small Business. http://smallbusiness.yahoo.com/domains/?p=BESTDEAL - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Exceptions design
I agree with you about don´t show SQL errors to a normal user I forgot to say that I am doing just now a part for an administrator user and I want to show the error most clear as possible. Maybe I should use a log message. Once it is defined that (tell me if I haven´t understood you): a) I must do an extra request to the database in order to know if the user exists to show the user the ActionMessages. b) I must create a general page error for another errors (using ModuleException, for example?) Are the next steps correct? 1) Use the action methods for local errors. For local errors I mean the errors which will be shown to the user at the same page where it is the form. 2) Use the bean methods for general errors. For general error I mean an error which will be shown at an error page. (using ModuleException). Thanks From: Dave Newton <[EMAIL PROTECTED]> Reply-To: "Struts Users Mailing List" To: Struts Users Mailing List Subject: Re: Exceptions design Date: Sun, 4 Feb 2007 09:41:23 -0800 (PST) --- Francisco Exposito Aguilera wrote: > What is the best way to show the user this sql error? I'm skeptical that you'd want to show the *user* an SQL error; my experience has been that it's best to wrap up such exceptions in an application-specific exception and report a general system error (or even a database error) and leave the specifics to a log message, email or IM to the admin, etc. > 2.Before execute the createUser bean method, execute > another method to check if the user already exists. > If it exists, use ActionMessages in the action > class to show the error in the same createUser.jsp > file. > > That means that if the user doesn´t exist, the > action method will access, at least twice to the > database, one for check if the user exists and one > for create it. I would think you'd have to do that anyway. > java.sql.SQLException: ORA-1: unique restriction > (PK_USER) violated > > a) Primary key is violated (java.sql.SQLException: > ORA-1: unique > restriction (PK_USER) violated) > > b) Name and both surnames are unique > (java.sql.SQLException: ORA-1: > unique restriction (U_NAME_SURNAME1_SURNAME2_U) > violated) I would most certainly *not* expose *any* system internals on a user-accessible web page. > Depending on the exception, I want to show primary > key exists or name and surnames exists with another > primary key Useful for developer, useless for user. All the *user* needs to know that another user with the same username exists and they need to choose another username or if they forgot their password they can click here, etc.) Keep user messages simple and jargon-free. It's easy enough to capture complete failure info for the developer somewhere else. (You can't restrict on just their real name because people have the same names sometimes.) d. Don't get soaked. Take a quick peak at the forecast with the Yahoo! Search weather shortcut. http://tools.search.yahoo.com/shortcuts/#loc_weather - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Dale rienda suelta a tu tiempo libre. Mil ideas para exprimir tu ocio con MSN Entretenimiento. http://entretenimiento.msn.es/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [S2] issue
True, thanks for the additional comments. I tried to keep my post short, so I concentrated on expressions only... :) Btw, the solution "with extra EL sauce" was what I had originally in my code: And yes, that works... However, I never enjoyed having JSP code (including EL) in my pages, unless absolutely necessary. So far, I haven't really bumped into anything that couldn't be solved with S2 tags with some OGNL :) Regards, Dj. -Original Message- From: Dave Newton [mailto:[EMAIL PROTECTED] Sent: Sunday, February 04, 2007 5:44 PM To: Struts Users Mailing List Subject: RE: [S2] issue --- Djordje Trifunovic <[EMAIL PROTECTED]> wrote: > because unlike in and some other > tags, in %{...} cannot be omitted. Just as a clarification; the reason it can't be omitted in *your* case is because you needed to evaluate an expression to be used as the name attribute. Using would retrieve a value from package.properties keyed with "package.text1". Using would retrieve a value from package.properties set with whatever your Action set its property packageText1Key to. Using would retrieve a value keyed with whatever you pkgtxt1 to, for example, , which evaluates an immediate string. Similarly, if you then #pkgtxt1 would evaluate to whatever the Action had set its packageText1Key property to. Mmmm, OGNL, with extra EL sauce. If you made it this far, try (in a JSP 2.0 container): And throw yet another different EL in there for grins. :D Dave Sucker-punch spam with award-winning protection. Try the free Yahoo! Mail Beta. http://advision.webevents.yahoo.com/mailbeta/features_spam.html - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Producing links
--- Tom Schneider <[EMAIL PROTECTED]> wrote: > I think the idea here is that you'd want to do > something like: > > bundle_key="preferences> > > Yeah, I realized that after I posted. I should probably have a cooling-off or 5-day waiting period before I'm allowed to post, really :/ d. Do you Yahoo!? Everyone is raving about the all-new Yahoo! Mail beta. http://new.mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Producing links
Joe you're assessment is correct. There is usually a 1 to 1 mapping between JSP tag and UI component. Right now the form tag and url tag duplicate several pieces of key url building logic. I spent some time abstracting away url building this weekend. I'm not far enough along to actually submit a patch, but I think this would greatly reduce the duplication of code. This is an issue for me because one of the project that I lead, tabletags, also does a lot with building up url's. Let me know if your interested in seeing some of this and I'll post the basic API and default implementations of this new urlbuilding functionality. The other option would be to add this functionality to the existing tag. I'm not sure if this makes sense from an API perspective--it may get a little weird if you allow tags to be nested within, and also allow the body content of the to be the text within the html anchor tag. From that perspective, a seperate tag makes more sense. It would also depend on how similar the ftl templates are and whether the differences are enough to warrant a seperate template. Tom Joe Germuska wrote: There's an open ticket for this issue https://issues.apache.org/struts/browse/WW-1517 I assigned it to myself, since I, too, am interested in such functionality, but I'm looking for some suggestions from someone, anyone with more familiarity with the architectural model for the S2 tags because I don't quite see how to maximize reuse (because it's essentially a hybrid of the and tags and I'm not sure how to blend them while holding to what seems to be the model of a single component object per tag. Maybe we could make a completely new component object, but then the question is how to not have duplicate code with the Anchor and Url components. Joe On 2/4/07, Gonçalo Luiz <[EMAIL PROTECTED]> wrote: Hello, Even though the method I'm using to produce links is working, I think of it like a little bit awkward. An example of what I'm saying is: "> Is there a more "elegant" way of producing links that does not involve this "sub-tag" schema ? Thank you. Best Regards, -- Gonçalo Luiz - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Producing links
I think the idea here is that you'd want to do something like: To me, this makes sense because there were many places where I used an ww:url tag and a ww:a tag directly after it, so having one tag that would handle the functionality of both would be useful. Tom Dave Newton wrote: --- Gonçalo Luiz <[EMAIL PROTECTED]> wrote: "> Is there a more "elegant" way of producing links that does not involve this "sub-tag" schema ? Like what? That's how the tag works, it has an href and the text is the body. If you want to automagicate it write a custom tag, but I'm not entirely sure it would be worth it. d. Do you Yahoo!? Everyone is raving about the all-new Yahoo! Mail beta. http://new.mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [s2] Autopopupation of fields fails with "enctype="multipart/form-data" in form
Hi Zafer, I would: 1) check the archives of this mailing list from the last 2 weeks, there was a thread about fileupload issues (parameters are not always set from such form). One of the hints was to use some magical filter in front of the application. It is supposed to clear sth. 2) check if you have any custom filter in front of your action - the multipart parser requires a 'virgin' request object, without accessing any params in it prior to multiparse analysis. If you try to operate on the request earlier - multiparser is not able to finish his task. regards Dariusz Wojtas On 2/4/07, zafer Mohamed <[EMAIL PROTECTED]> wrote: I have a form with the enctype set to "enctype="multipart/form-data" as I am uploading a file, the form also contains some other fields. On submission the autopopulation of other fields fails, but it works correctly if I remove the enctype="multipart/form-data". Any idea..? Thanks Zafer - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Exceptions design
From: Dave Newton <[EMAIL PROTECTED]> Reply-To: "Struts Users Mailing List" To: Struts Users Mailing List Subject: Re: Exceptions design Date: Sun, 4 Feb 2007 09:41:23 -0800 (PST) --- Francisco Exposito Aguilera wrote: > What is the best way to show the user this sql error? I'm skeptical that you'd want to show the *user* an SQL error; my experience has been that it's best to wrap up such exceptions in an application-specific exception and report a general system error (or even a database error) and leave the specifics to a log message, email or IM to the admin, etc. > 2.Before execute the createUser bean method, execute > another method to check if the user already exists. > If it exists, use ActionMessages in the action > class to show the error in the same createUser.jsp > file. > > That means that if the user doesn´t exist, the > action method will access, at least twice to the > database, one for check if the user exists and one > for create it. I would think you'd have to do that anyway. > java.sql.SQLException: ORA-1: unique restriction > (PK_USER) violated > > a) Primary key is violated (java.sql.SQLException: > ORA-1: unique > restriction (PK_USER) violated) > > b) Name and both surnames are unique > (java.sql.SQLException: ORA-1: > unique restriction (U_NAME_SURNAME1_SURNAME2_U) > violated) I would most certainly *not* expose *any* system internals on a user-accessible web page. > Depending on the exception, I want to show primary > key exists or name and surnames exists with another > primary key Useful for developer, useless for user. All the *user* needs to know that another user with the same username exists and they need to choose another username or if they forgot their password they can click here, etc.) Keep user messages simple and jargon-free. It's easy enough to capture complete failure info for the developer somewhere else. (You can't restrict on just their real name because people have the same names sometimes.) d. Don't get soaked. Take a quick peak at the forecast with the Yahoo! Search weather shortcut. http://tools.search.yahoo.com/shortcuts/#loc_weather - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _ Grandes éxitos, superhéroes, imitaciones, cine y TV... http://es.msn.kiwee.com/ Lo mejor para tu móvil. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Struts-Faces: validator
It seens to me onsubmit of s:form is never executed. Thanks, Rodrigo Pereira On 2/4/07, Rodrigo Pereira <[EMAIL PROTECTED]> wrote: Hi Peter, Is there any hint for this? I can see the js printed on the page, but it looks like it never called those functions and it goes directly to the action. Thanks, Rodrigo Pereira On 2/3/07, PETER BLIZNAK <[EMAIL PROTECTED]> wrote: > Yes it does work, I am using on every single page. > > Rodrigo Pereira <[EMAIL PROTECTED]> wrote: hi All, > does anybody know if validator work with struts-faces? > I have read a lot of tutorials on the Internet, but no success at all > > > Thanks, > Rodrigo Pereira > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Exceptions design
--- Francisco Exposito Aguilera wrote: > What is the best way to show the user this sql error? I'm skeptical that you'd want to show the *user* an SQL error; my experience has been that it's best to wrap up such exceptions in an application-specific exception and report a general system error (or even a database error) and leave the specifics to a log message, email or IM to the admin, etc. > 2.Before execute the createUser bean method, execute > another method to check if the user already exists. > If it exists, use ActionMessages in the action > class to show the error in the same createUser.jsp > file. > > That means that if the user doesn´t exist, the > action method will access, at least twice to the > database, one for check if the user exists and one > for create it. I would think you'd have to do that anyway. > java.sql.SQLException: ORA-1: unique restriction > (PK_USER) violated > > a) Primary key is violated (java.sql.SQLException: > ORA-1: unique > restriction (PK_USER) violated) > > b) Name and both surnames are unique > (java.sql.SQLException: ORA-1: > unique restriction (U_NAME_SURNAME1_SURNAME2_U) > violated) I would most certainly *not* expose *any* system internals on a user-accessible web page. > Depending on the exception, I want to show primary > key exists or name and surnames exists with another > primary key Useful for developer, useless for user. All the *user* needs to know that another user with the same username exists and they need to choose another username or if they forgot their password they can click here, etc.) Keep user messages simple and jargon-free. It's easy enough to capture complete failure info for the developer somewhere else. (You can't restrict on just their real name because people have the same names sometimes.) d. Don't get soaked. Take a quick peak at the forecast with the Yahoo! Search weather shortcut. http://tools.search.yahoo.com/shortcuts/#loc_weather - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Producing links
--- Joe Germuska <[EMAIL PROTECTED]> wrote: > There's an open ticket for this issue > https://issues.apache.org/struts/browse/WW-1517 > > "> > > > > There's obvious base functionality like we're talking about here (an action or value or href, optional text from properties, styling, etc.) but adds a lot to deal with various AJAXy things. Are the tag classes twisted enough that it's difficult to roll the base functionality into and add the AJAXy stuff to an subclass? The same parameter stuff would be useful in . d. No need to miss a message. Get email on-the-go with Yahoo! Mail for Mobile. Get started. http://mobile.yahoo.com/mail - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[s2] Autopopupation of fields fails with "enctype="multipart/form-data" in form
I have a form with the enctype set to "enctype="multipart/form-data" as I am uploading a file, the form also contains some other fields. On submission the autopopulation of other fields fails, but it works correctly if I remove the enctype="multipart/form-data". Any idea..? Thanks Zafer Get your own web address. Have a HUGE year through Yahoo! Small Business. http://smallbusiness.yahoo.com/domains/?p=BESTDEAL
Re: Producing links
--- Gonçalo Luiz <[EMAIL PROTECTED]> wrote: > "> > > > > Is there a more "elegant" way of producing links > that does not involve this "sub-tag" schema ? Like what? That's how the tag works, it has an href and the text is the body. If you want to automagicate it write a custom tag, but I'm not entirely sure it would be worth it. d. Do you Yahoo!? Everyone is raving about the all-new Yahoo! Mail beta. http://new.mail.yahoo.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Producing links
There's an open ticket for this issue https://issues.apache.org/struts/browse/WW-1517 I assigned it to myself, since I, too, am interested in such functionality, but I'm looking for some suggestions from someone, anyone with more familiarity with the architectural model for the S2 tags because I don't quite see how to maximize reuse (because it's essentially a hybrid of the and tags and I'm not sure how to blend them while holding to what seems to be the model of a single component object per tag. Maybe we could make a completely new component object, but then the question is how to not have duplicate code with the Anchor and Url components. Joe On 2/4/07, Gonçalo Luiz <[EMAIL PROTECTED]> wrote: Hello, Even though the method I'm using to produce links is working, I think of it like a little bit awkward. An example of what I'm saying is: "> Is there a more "elegant" way of producing links that does not involve this "sub-tag" schema ? Thank you. Best Regards, -- Gonçalo Luiz - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Joe Germuska [EMAIL PROTECTED] * http://blog.germuska.com "The truth is that we learned from João forever to be out of tune." -- Caetano Veloso
Exceptions design
Hello all, I have a doubt about how design the exceptions in my struts project. I have the action classes and the bean classes. The action classes execute methods from bean classes, which connect to the database. Supposing I am trying to create a user in one of my web pages and the user I want to create exists. What is the best way to show the user this sql error? 1.Throw the exception in the bean class to the struts ModuleException and show a typical error page. (I hope this is not the best way because I don´t like it). 2.Before execute the createUser bean method, execute another method to check if the user already exists. If it exists, use ActionMessages in the action class to show the error in the same createUser.jsp file. That means that if the user doesn´t exist, the action method will access, at least twice to the database, one for check if the user exists and one for create it. 3.Execute the createUser bean method using try and finally but without catch; and throw the SQL exception. public OTDUser validUser (String dni, String passwd) throws SQLException { try { Connection to the database and results } finally { Close resultSet, statement and connection } } The exception will be catched by the action class, where there is a catch(SQLException), which will receive the exception from the bean method java.sql.SQLException: ORA-1: unique restriction (PK_USER) violated And with ActionMessages show it in the same createUser.jsp. But now, can I know if the SQLException is caused by: a) Primary key is violated (java.sql.SQLException: ORA-1: unique restriction (PK_USER) violated) b) Name and both surnames are unique (java.sql.SQLException: ORA-1: unique restriction (U_NAME_SURNAME1_SURNAME2_U) violated) Depending on the exception, I want to show primary key exists or name and surnames exists with another primary key 4.Any suggestion? Thanks a lot. _ Horóscopo, tarot, numerología... Escucha lo que te dicen los astros. http://astrocentro.msn.es/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [S2] issue
--- Djordje Trifunovic <[EMAIL PROTECTED]> wrote: > because unlike in and some other > tags, in %{...} cannot be omitted. Just as a clarification; the reason it can't be omitted in *your* case is because you needed to evaluate an expression to be used as the name attribute. Using would retrieve a value from package.properties keyed with "package.text1". Using would retrieve a value from package.properties set with whatever your Action set its property packageText1Key to. Using would retrieve a value keyed with whatever you pkgtxt1 to, for example, , which evaluates an immediate string. Similarly, if you then #pkgtxt1 would evaluate to whatever the Action had set its packageText1Key property to. Mmmm, OGNL, with extra EL sauce. If you made it this far, try (in a JSP 2.0 container): And throw yet another different EL in there for grins. :D Dave Sucker-punch spam with award-winning protection. Try the free Yahoo! Mail Beta. http://advision.webevents.yahoo.com/mailbeta/features_spam.html - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Producing links
Hello, Even though the method I'm using to produce links is working, I think of it like a little bit awkward. An example of what I'm saying is: "> Is there a more "elegant" way of producing links that does not involve this "sub-tag" schema ? Thank you. Best Regards, -- Gonçalo Luiz - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Use tiles:getAsString to return a key to s:text
Hello, Thank you very much, it indeed worked. Regards, Gonçalo Luiz. On 04/02/07, Djordje Trifunovic <[EMAIL PROTECTED]> wrote: Hi Gonçalo, Nesting tag as an attribute of another tag is not supported. To accomplish this particular task of passing key through tiles, try this instead: Regards, Dj. -Original Message- From: Gonçalo Luiz [mailto:[EMAIL PROTECTED] Sent: Saturday, February 03, 2007 7:53 PM To: Dave Newton Cc: Struts Users Mailing List Subject: Re: Use tiles:getAsString to return a key to s:text Hello Dave, Thank you for your answer. However what I want to achieve is a little more than just internationalization, what I can do by simply using . What I'm seeking is to put a key in tiles configuration file (usually tiles.xml) like: that gets included in the page by using . However by doing just this I get literally "some.key" on my pages title. So what I'm tring is to do use that string in a tag like "/> however I'm getting one of two problems: 1 - If i use the above statement I get a "expecting equal symbol" exception 2 - if I use Oren's suggestion I get literally in my page's title. Is it clear whatI'm trying to achieve ? Best Regards, Gonçalo Luiz. On 03/02/07, Dave Newton <[EMAIL PROTECTED]> wrote: > --- Gonçalo Luiz <[EMAIL PROTECTED]> wrote: > > I'd like to do something like > name=" > name="title"/>"/> to internationalize my page title. > > You want to put the key in your tiles file? > > S2 properties are already I18N-aware: > > http://cwiki.apache.org/WW/localization.html > > d. > > > > > > Any questions? Get answers on any topic at www.Answers.yahoo.com. Try it now. > -- Gonçalo Luiz - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- Gonçalo Luiz - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Struts-Faces: validator
Hi Peter, Is there any hint for this? I can see the js printed on the page, but it looks like it never called those functions and it goes directly to the action. Thanks, Rodrigo Pereira On 2/3/07, PETER BLIZNAK <[EMAIL PROTECTED]> wrote: Yes it does work, I am using on every single page. Rodrigo Pereira <[EMAIL PROTECTED]> wrote: hi All, does anybody know if validator work with struts-faces? I have read a lot of tutorials on the Internet, but no success at all Thanks, Rodrigo Pereira - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [S2] issue
Searching for some more documentation on net about OGNL and its connection to WW/Struts2, I think I finally isolated what was causing some confusion in my case. Since it may useful for some other newbies, here is what works in the situation from the previous post: This doesn't work: because unlike in and some other tags, in %{...} cannot be omitted. This wouldn't work either: because unlike variables, for non-root objects in WW and Struts2 prefix # cannot be omitted. The reasons become pretty clear after one digs deeper into OGNL in WW/S2... but let's not make the post too big :) Regards, Dj. -Original Message- From: Djordje Trifunovic [mailto:[EMAIL PROTECTED] Sent: Friday, February 02, 2007 10:34 PM To: 'Struts Users Mailing List' Subject: RE: [S2] issue Wesley - yes, that's it. Thanks for both clarifying my question and answering it. :) Now, this really solves the problem when the property is on value stack. Is there a way to access other (non-root) objects using this notation? E.g. I have attribute "title" defined in Tiles, also with a key rather than the direct text. In the layout I do: Normally, I could access this using #attr['title'], but the same problem appears with . Sure, I can always solve it by putting it value to stack first before using %{...}, but I'd really like to avoid that step if it is not necessary. I would appreciate if you could send me off-list the post about OGNL. Thanks! Dj. -Original Message- From: Wesley Wannemacher [mailto:[EMAIL PROTECTED] Sent: Friday, February 02, 2007 9:12 PM To: Struts Users Mailing List Subject: RE: [S2] issue I could be wrong, but you may be misunderstanding the poster's intent. He has a variable on the value stack that indicates which property key he wants to retrieve. If my understanding is correct, then I would not really be any help, but has the OP tried: ? P.S. I have a post from last week or before where I had a bunch of trouble understanding OGNL and it might help you if you want it off-list. > -Original Message- > From: Ian Roughley [mailto:[EMAIL PROTECTED] > Sent: Friday, February 02, 2007 3:07 PM > To: Struts Users Mailing List > Subject: Re: [S2] issue > > I think you may be confused, you say > > The value of myKey is "some.resource.key", and in the > property file I have: > > some.resource.key = Some text > > In fact, "some.resource.key" is the key and "some text" is the value. > > Try - > > > > > /Ian > > -- > From Down & Around, Inc. > Innovative IT Solutions > Software Architecture * Design * Development > ~ > web: www.fdar.com > email [EMAIL PROTECTED] > phone:617.821.5430 > ~ > > > > Djordje Trifunovic wrote: > > Hi, > > > > > > > > Using Struts2 (2.0.5 snapshot) in a project, I hit the > following problem: I > > have a resource bundle key that I need to use with > tag to retrieve > > a text from my resource bundle. The name of the key is in a > property myKey > > in the value stack. The value of myKey is > "some.resource.key", and in the > > property file I have: > > > > > > > > some.resource.key = Some text > > > > > > > > I tried: > > > > > > > > > > > > > > > > but that doesn't work as I expected. Instead of getting > "Some text" on my > > page, or at least "some.resource.key", I get "#myKey" > instead. Just to be > > sure everything is ok in the value stack, I tried: > > > > > > > > > > > > > > > > And that returns "some.resource.key", as expected. Am I > missing something > > here? > > > > > > > > Thanks, > > > > Djordje Trifunovic > > > > > > > > PS. I am sorry if the issue was already discussed. I didn't > find it quickly > > searching through archive. > > > > > > > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
render output
Hi all, is there a way to avoid that the action property is rendered with the application name (e.g --> ) ? What i need for a special case is that the output is . If this is not possible , is it possible to use the normal html-form () tag and bind it to an actionForm ? regards ivan --- Begin Message --- Hi all, is there a way to avoid that the action property is rendered with the application name (e.g --> ) ? What i need for a special case is that the output is . If this is not possible , is it possible to use the normal html-form () tag and bind it to an actionForm ? regards ivan --- End Message --- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [S2] How to use a bundle message in a validation
--- Struts2 Fan <[EMAIL PROTECTED]> wrote: > struts.properties > errorage= src="images/mistake.jpg" /> > Am I doing something wrong? I don't know what the "name" attribute is; I only know about "id" and "class" for styling-type things. If you seriously want a different div for each field (which strikes me odd, but I can imagine use-cases) then you will probably want to write an FTL that constructs a div id/class name out of the field name or something. d. 8:00? 8:25? 8:40? Find a flick in no time with the Yahoo! Search movie showtime shortcut. http://tools.search.yahoo.com/shortcuts/#news - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Struts-Faces: validator
Rodrigo, AFAIK that was possible. Regards, - Original Message - From: "Rodrigo Pereira" <[EMAIL PROTECTED]> To: "Struts Users Mailing List" Sent: Saturday, February 03, 2007 10:39 PM Subject: Struts-Faces: validator hi All, does anybody know if validator work with struts-faces? I have read a lot of tutorials on the Internet, but no success at all Thanks, Rodrigo Pereira - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.5.432 / Virus Database: 268.17.20/664 - Release Date: 2/02/2007 15:42 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Use tiles:getAsString to return a key to s:text
Hi Gonçalo, Nesting tag as an attribute of another tag is not supported. To accomplish this particular task of passing key through tiles, try this instead: Regards, Dj. -Original Message- From: Gonçalo Luiz [mailto:[EMAIL PROTECTED] Sent: Saturday, February 03, 2007 7:53 PM To: Dave Newton Cc: Struts Users Mailing List Subject: Re: Use tiles:getAsString to return a key to s:text Hello Dave, Thank you for your answer. However what I want to achieve is a little more than just internationalization, what I can do by simply using . What I'm seeking is to put a key in tiles configuration file (usually tiles.xml) like: that gets included in the page by using . However by doing just this I get literally "some.key" on my pages title. So what I'm tring is to do use that string in a tag like "/> however I'm getting one of two problems: 1 - If i use the above statement I get a "expecting equal symbol" exception 2 - if I use Oren's suggestion I get literally in my page's title. Is it clear whatI'm trying to achieve ? Best Regards, Gonçalo Luiz. On 03/02/07, Dave Newton <[EMAIL PROTECTED]> wrote: > --- Gonçalo Luiz <[EMAIL PROTECTED]> wrote: > > I'd like to do something like > name=" > name="title"/>"/> to internationalize my page title. > > You want to put the key in your tiles file? > > S2 properties are already I18N-aware: > > http://cwiki.apache.org/WW/localization.html > > d. > > > > > > Any questions? Get answers on any topic at www.Answers.yahoo.com. Try it now. > -- Gonçalo Luiz - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[S2] How to use a bundle message in a validation
Hi all, I put the message on the right hand side of the tag with writing my own theme. (Thanks for all) But i cannot put the tag on the message. struts.properties errorage= myAction-validation.xml 13 19 It writes "errorage" on the page not the div element. Am I doing something wrong?
Transfer Object (TO) vs. Entity Bean
Hello. I have a question concerning transfer objects. If a transfer object contains another object represented by a POJO, is this contained object also considered a transfer object or simply an entity bean? Is their any literature that discusses this? Any help would be appreciated. Thank you. - Asad - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]