You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Alex Colic <ac...@yahoo.com> on 2001/08/26 16:20:58 UTC
Need help with error messages quick please
Hi,
I am using the latest cut of Struts from the nightly build. I need the iterate function.
Something has happened to my error messages. In my action class if a method fails I set the
following error:
errors.add(ActionErrors.GLOBAL_ERROR, new ActionError("error.invalidBidAmount"));
I then save the error via:
if(!errors.empty())
{
this.saveErrors(request,errors);
return (new ActionForward(mapping.getInput()));
}
When the user is redirect back to the page they came from all the user sees is the error.header
msg.
I have this tag in my web page after the body tag:
<html:errors/>
I must be missing something. Could someone set me on the right track.
Alex
=====
Regards
Alex Colic, HBA, B. Ed
PopWare Inc. "Driving down the cost of conversions!"
E-Mail: Alex.Colic@pop-ware.com
Tel: 1-905-777-8171 ext. 104
Fax: 1-905-777-0132
__________________________________________________
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/
Re: Need help with error messages quick please
Posted by ma...@tumbleweed.com.
Are you sure you have the key defined in your resources file? Unless you
have the 'null' init param set to false, no text will be displayed if you
forgot to define the key, or misspelled it. (For this reason, I make a habit
of setting 'null' to false, so that I'll see something to remind me to
define the key.)
--
Martin Cooper
----- Original Message -----
From: "Alex Colic" <ac...@yahoo.com>
To: <st...@jakarta.apache.org>
Sent: Sunday, August 26, 2001 7:20 AM
Subject: Need help with error messages quick please
> Hi,
>
> I am using the latest cut of Struts from the nightly build. I need the
iterate function.
>
> Something has happened to my error messages. In my action class if a
method fails I set the
> following error:
>
> errors.add(ActionErrors.GLOBAL_ERROR, new
ActionError("error.invalidBidAmount"));
>
> I then save the error via:
>
> if(!errors.empty())
> {
> this.saveErrors(request,errors);
> return (new ActionForward(mapping.getInput()));
> }
>
> When the user is redirect back to the page they came from all the user
sees is the error.header
> msg.
>
> I have this tag in my web page after the body tag:
>
> <html:errors/>
>
> I must be missing something. Could someone set me on the right track.
>
> Alex
>
> =====
> Regards
>
> Alex Colic, HBA, B. Ed
> PopWare Inc. "Driving down the cost of conversions!"
> E-Mail: Alex.Colic@pop-ware.com
> Tel: 1-905-777-8171 ext. 104
> Fax: 1-905-777-0132
>
> __________________________________________________
> Do You Yahoo!?
> Make international calls for as low as $.04/minute with Yahoo! Messenger
> http://phonecard.yahoo.com/
>