Use of Tiles

2005-02-27 Thread Mark Benussi
I use tiles in my webapp but only to replace the deprecated struts template methodology. What I want to know is can I do define a tile.. Similar I suppose to a taglib. My jsp would look like the following tile action=/myoldstrutsaction.do !-- Then place html and use beans exposed by

Re: AW: Struts Approach

2005-02-27 Thread Mike Millson
On Sat, 2005-02-26 at 11:26, Tim Christopher wrote: I'm also a little concerned that my domain object (Customer.java) is also my DTO - is this good practice? Take a look at the following article: http://www.javaperformancetuning.com/news/roundup050.shtml I think the author makes a good

Iterate over validation errors?

2005-02-27 Thread Adam Jenkins
Hi All, Is there a simple way to iterate over all the validation errors. I don't want to just do html:errors/ I want to actually for a ulli.../li/ul of all the errors that occured when submitting the page. Is this possible? Does anyone have an example I could use? Cheers Adam

Re: Iterate over validation errors?

2005-02-27 Thread Erik Weber
Last I checked, Struts came configured to do what I think you are asking by default. This is an example of the (Struts 1.1) ApplicationResources.properties file: #header and footer for form validation error messages errors.header=table width=100% border=0 cellspacing=0 cellpadding=0tr

Re: Iterate over validation errors?

2005-02-27 Thread Adam Jenkins
Thanks for that, I'll give it a go. Is there anyway you can accomplish it without having to put html in the resource bundle? On Sun, 2005-02-27 at 19:04 -0500, Erik Weber wrote: Last I checked, Struts came configured to do what I think you are asking by default. This is an example of the

RE: Iterate over validation errors?

2005-02-27 Thread Joe Hertz
There's one improvement on that method: errors.prefix=li errors.suffix=/li So you don't need to put the markup into each error definition in your properties file. If you don't want markup in it at all, you can do something like logic:messagesPresent UL html:messages id=error LIbean:write

RE: Iterate over validation errors?

2005-02-27 Thread Joe Hertz
There's one improvement on that method: errors.prefix=li errors.suffix=/li So you don't need to put the markup into each error definition in your properties file. If you don't want markup in it at all, you can do something like logic:messagesPresent UL html:messages id=error LIbean:write

Re: Iterate over validation errors?

2005-02-27 Thread Erik Weber
You could leave errors.header and errors.footer blank, and then wrap your html:errors with the markup. Somewhere in the properties file you're going to have to at least specify (markup) that you are using a bulleted list if I'm not mistaken. There also is a way that you could iterate over the

Re: Iterate over validation errors?

2005-02-27 Thread Joe Germuska
html:messages is an iterator through messages, so you can leave the HTML out of the resources file: For the example below, here's how to do it with html:messages instead: div class=error ul html:messages id=msg lic:out value=${msg} //li /html:messages /ul /div Despite the name, html:messages

Re: Iterate over validation errors?

2005-02-27 Thread Erik Weber
Here are a couple of old posts I saved that might help too: At 5:10 PM -0500 11/8/04, Erik Weber wrote: Here is a way to do it that works with 1.1: logic:messagesPresent name=org.apache.struts.action.ERROR property=username bean:message key=error.username.required/ /logic:messagesPresent

Re: Iterate over validation errors?

2005-02-27 Thread Erik Weber
Heh, just ignore everything I wrote and listen to Joe. :) Erik Joe Germuska wrote: html:messages is an iterator through messages, so you can leave the HTML out of the resources file: For the example below, here's how to do it with html:messages instead: div class=error ul html:messages id=msg

RequestURI (Action not JSP)

2005-02-27 Thread Ben Taylor
Can anyone tell me if it is possible to extract the name of the current action from within a JSP? ie. /welcome.do, or /secure/login.do... Is there a tag that can do this - maybe within one of the additional tag libraries? Thank you in advance.

Re: Uploading: And a Wish List for Struts v1.3 and v2.0 Jericho

2005-02-27 Thread Dakota Jack
The wiki list is for trying to convince the struts developers to take Struts 1.3 chain to a place that alternative upload applications can be submitted? I think this is an irrelevant response to a substantial question. Jacki On Sat, 26 Feb 2005 20:14:28 -0800, Craig McClanahan [EMAIL

Re: Uploading: And a Wish List for Struts v1.3 and v2.0 Jericho

2005-02-27 Thread Dakota Jack
I wish I had never said wish list. I was talking about a KIND OF INTERFACE needed in Struts and the example application is just to show what KIND OF INTERFACE might be helpful. DId no one get that? I try to save space by not spelling out what seems to be obvious and I get these answers from

Re: [OT] Re: Struts Approach

2005-02-27 Thread Andrew Hill
snip Not to hit below the belt, but the only place that I have seen that naming used in practice is in the Win32/COM world. Can you name another? ;-) /snip We do it as part of our coding conventions (we also do the Abstractxxx thing too). Im rather pro doing it that way too. Mostly its a

Re: Uploading: And a Wish List for Struts v1.3 and v2.0 Jericho

2005-02-27 Thread Dakota Jack
If you check the discussions I have had with Niall on this on this list, that might be helpful. He understands clearly what I am talking about and where the extension points in 1.3 need to be tweeked in relation to this real problem. This submission was to be a helpful addition to that

Re: RequestURI (Action not JSP)

2005-02-27 Thread Erik Weber
I don't have the best answer, but I've got two ideas for you. One is to remember that the ActionMapping (which inherits from ActionConfig) instance is available to the setup action before you transfer control to your JSP. Not sure if that would help or not. Also, I found it very helpful to

help with bean:write

2005-02-27 Thread Richard Reyes
Hello Guys, Please advise I have this code below... and i need to add the username property to the javascript. td align=right bgcolor=#ff bean:write name=idRuser property=username/nbsp; html:button property=btnDelete value=Delete

Encoding problems with russian / bean:write / html:text

2005-02-27 Thread Leon Rosenberg
Hi, First of all, I'm not very experienced with encoding, so it's could be a very newbie problem. I have a website-builder, which generates a complete struts web-app out of an xml file. However I now have a customer who wants to present his data in russian and german. The data for

Encoding problems with russian / bean:write / html:text

2005-02-27 Thread Leon Rosenberg
Hi, First of all, I'm not very experienced with encoding, so it's could be a very newbie problem. I have a website-builder, which generates a complete struts web-app out of an xml file. However I now have a customer who wants to present his data in russian and german. The data for