struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Martin Cooper" <martin.coo...@tumbleweed.com>
Subject Re: error with parameters
Date Tue, 10 Oct 2000 03:27:37 GMT
I suggested a simple change to enable this a few weeks ago. Unfortunately
(in my opinion), the discussion got a little carried away with inventing
quite sophisticated error reporting mechanisms.

What I had suggested was adding an errors.format value in addition to the
existing errors.header and errors.footer values. I'll admit that this is not
nearly as flexible as some of the other suggestions made, but it would be a
very simple addition to the existing <struts:errors> tag that wouldn't break
any existing code.

--
Martin Cooper
Tumbleweed Communications

----- Original Message -----
From: "Christophe Thiebaud" <cthiebaud@stylo.it>
To: <struts-user@jakarta.apache.org>
Sent: Monday, October 09, 2000 10:29 AM
Subject: error with parameters


Is there a way to use parameterized errors with struts ?

in the example application the file ApplicationResources.properties
has several string with a {0] tag,
(e.g. linkSubscription.noSubscription=No subscription under attribute {0}

but these strings are used only to throw  JspException objects, like in:

// Print this element to our output writer
JspWriter writer = pageContext.getOut();
try {
    writer.print(results.toString());
} catch (IOException e) {
    throw new JspException
(messages.getMessage("linkSubscription.io", e.toString()));
}

there is no way currently to have the struts tag ErrorsTag handle
parameterized
errors.

how do struts users manage that ?

Christophe



Mime
View raw message