You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by subhendukumar mohanty <su...@infy.com> on 2002/03/14 02:07:04 UTC
Problem in HTML:ERROR tag
Hi
I am setting the action error in my action class. Then when the error displays in the screen it appends "null" in front and end of the message. For example if the error message is "Error occurred", it shows as "null Error Occurred null". I am using struts with visualage 4.0.
I am using struts 1.0.1 and modified the form tag to work for websphere test environment.
Any Help??
Thanks,
Subhendu
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Problem in HTML:ERROR tag
Posted by Jay sissom <js...@toybox.uits.indiana.edu>.
Struts shouldn't print NULL before and after your errors if you don't put
errors.header and errors.footer in your Application Resources file,
correct?
We all understand how it is supposed to work. We don't understand why
"null" is printing on the page. It didn't used to print. Has the
behaviour of Struts changed so that errors.header and errors.footer is
required? If so, the documentation should have been updated to reflect
that.
On Thu, 14 Mar 2002, keithBacon wrote:
> you can put HTML in your error messages
>
> errors.header=<font color="red" size="+1"><ul>
> errors.footer=</ul></font>
>
> UserValidator.userID.must.be.entered=<li>moron! enter required data</li>
>
> I think there was talk on this list about a way of keeping all the html in your
> jsp. The above way is a bit of a bodge but commonly used.
>
>
> --- Jay sissom <js...@toybox.uits.indiana.edu> wrote:
> > If we do that, the errors would bring like this:
> >
> > abcderror,error,errorefgh, correct? Isn't that just as bad or worse than
> > the null problem?
> >
> > We're having this problems with tomcat also.
> >
> > Jay
> >
> > On Thu, 14 Mar 2002, nsg wrote:
> >
> > > I had met the problem.
> > > you append the "errors.head=abcd","errors.footer=efgh" two lines in your
> > > resource file.
> > > it will be OK.
> > >
> > > hope helps
> > >
> > > Laker
> > > ----- Original Message -----
> > > From: "subhendukumar mohanty" <su...@infy.com>
> > > To: <st...@jakarta.apache.org>
> > > Sent: Thursday, March 14, 2002 10:07 AM
> > > Subject: Problem in HTML:ERROR tag
> > >
> > >
> > > Hi
> > > I am setting the action error in my action class. Then when the error
> > > displays in the screen it appends "null" in front and end of the message.
> > > For example if the error message is "Error occurred", it shows as "null
> > > Error Occurred null". I am using struts with visualage 4.0.
> > >
> > > I am using struts 1.0.1 and modified the form tag to work for websphere
> > test
> > > environment.
> > >
> > > Any Help??
> > > Thanks,
> > > Subhendu
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:
> > > <ma...@jakarta.apache.org>
> > > For additional commands, e-mail:
> > > <ma...@jakarta.apache.org>
> > >
> > >
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:
> > <ma...@jakarta.apache.org>
> > > For additional commands, e-mail:
> > <ma...@jakarta.apache.org>
> > >
> >
> >
> > --
> > To unsubscribe, e-mail: <ma...@jakarta.apache.org>
> > For additional commands, e-mail: <ma...@jakarta.apache.org>
> >
>
>
> =====
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> Search the archive:-
> http://www.mail-archive.com/struts-user%40jakarta.apache.org/
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> Keith Bacon - Looking for struts work - South-East UK.
> phone UK 07960 011275
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Sports - live college hoops coverage
> http://sports.yahoo.com/
>
> --
> To unsubscribe, e-mail: <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Problem in HTML:ERROR tag
Posted by keithBacon <ke...@yahoo.com>.
you can put HTML in your error messages
errors.header=<font color="red" size="+1"><ul>
errors.footer=</ul></font>
UserValidator.userID.must.be.entered=<li>moron! enter required data</li>
I think there was talk on this list about a way of keeping all the html in your
jsp. The above way is a bit of a bodge but commonly used.
--- Jay sissom <js...@toybox.uits.indiana.edu> wrote:
> If we do that, the errors would bring like this:
>
> abcderror,error,errorefgh, correct? Isn't that just as bad or worse than
> the null problem?
>
> We're having this problems with tomcat also.
>
> Jay
>
> On Thu, 14 Mar 2002, nsg wrote:
>
> > I had met the problem.
> > you append the "errors.head=abcd","errors.footer=efgh" two lines in your
> > resource file.
> > it will be OK.
> >
> > hope helps
> >
> > Laker
> > ----- Original Message -----
> > From: "subhendukumar mohanty" <su...@infy.com>
> > To: <st...@jakarta.apache.org>
> > Sent: Thursday, March 14, 2002 10:07 AM
> > Subject: Problem in HTML:ERROR tag
> >
> >
> > Hi
> > I am setting the action error in my action class. Then when the error
> > displays in the screen it appends "null" in front and end of the message.
> > For example if the error message is "Error occurred", it shows as "null
> > Error Occurred null". I am using struts with visualage 4.0.
> >
> > I am using struts 1.0.1 and modified the form tag to work for websphere
> test
> > environment.
> >
> > Any Help??
> > Thanks,
> > Subhendu
> >
> >
> > --
> > To unsubscribe, e-mail:
> > <ma...@jakarta.apache.org>
> > For additional commands, e-mail:
> > <ma...@jakarta.apache.org>
> >
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> > For additional commands, e-mail:
> <ma...@jakarta.apache.org>
> >
>
>
> --
> To unsubscribe, e-mail: <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
>
=====
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Search the archive:-
http://www.mail-archive.com/struts-user%40jakarta.apache.org/
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Keith Bacon - Looking for struts work - South-East UK.
phone UK 07960 011275
__________________________________________________
Do You Yahoo!?
Yahoo! Sports - live college hoops coverage
http://sports.yahoo.com/
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Problem in HTML:ERROR tag
Posted by Jay sissom <js...@toybox.uits.indiana.edu>.
If we do that, the errors would bring like this:
abcderror,error,errorefgh, correct? Isn't that just as bad or worse than
the null problem?
We're having this problems with tomcat also.
Jay
On Thu, 14 Mar 2002, nsg wrote:
> I had met the problem.
> you append the "errors.head=abcd","errors.footer=efgh" two lines in your
> resource file.
> it will be OK.
>
> hope helps
>
> Laker
> ----- Original Message -----
> From: "subhendukumar mohanty" <su...@infy.com>
> To: <st...@jakarta.apache.org>
> Sent: Thursday, March 14, 2002 10:07 AM
> Subject: Problem in HTML:ERROR tag
>
>
> Hi
> I am setting the action error in my action class. Then when the error
> displays in the screen it appends "null" in front and end of the message.
> For example if the error message is "Error occurred", it shows as "null
> Error Occurred null". I am using struts with visualage 4.0.
>
> I am using struts 1.0.1 and modified the form tag to work for websphere test
> environment.
>
> Any Help??
> Thanks,
> Subhendu
>
>
> --
> To unsubscribe, e-mail:
> <ma...@jakarta.apache.org>
> For additional commands, e-mail:
> <ma...@jakarta.apache.org>
>
>
>
>
> --
> To unsubscribe, e-mail: <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Problem in HTML:ERROR tag
Posted by nsg <ns...@trans-cosmos.com.cn>.
I had met the problem.
you append the "errors.head=abcd","errors.footer=efgh" two lines in your
resource file.
it will be OK.
hope helps
Laker
----- Original Message -----
From: "subhendukumar mohanty" <su...@infy.com>
To: <st...@jakarta.apache.org>
Sent: Thursday, March 14, 2002 10:07 AM
Subject: Problem in HTML:ERROR tag
Hi
I am setting the action error in my action class. Then when the error
displays in the screen it appends "null" in front and end of the message.
For example if the error message is "Error occurred", it shows as "null
Error Occurred null". I am using struts with visualage 4.0.
I am using struts 1.0.1 and modified the form tag to work for websphere test
environment.
Any Help??
Thanks,
Subhendu
--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Problem in HTML:ERROR tag
Posted by Matt Barnicle <br...@barnicle.org>.
You need to initialize some values in your application resource properties
file. Set these two values:
errors.header=
errors.footer=
If you want all errors to be red, do this:
errors.header=<font color="red">
errors.footer=</font>
Got it?
- M@
On Wed, 13 Mar 2002, subhendukumar mohanty wrote:
> Hi
> I am setting the action error in my action class. Then when the error displays in the screen it appends "null" in front and end of the message. For example if the error message is "Error occurred", it shows as "null Error Occurred null". I am using struts with visualage 4.0.
>
> I am using struts 1.0.1 and modified the form tag to work for websphere test environment.
>
> Any Help??
> Thanks,
> Subhendu
>
>
> --
> To unsubscribe, e-mail: <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>