• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

more than html:error

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am using the validator framework and when i do form bean validation on fields I want the error messages to appear next to the field which generated the error rather then having html:error at the top of the page and displaying the errors as a batch

anyone know how to do this?
 
Ranch Hand
Posts: 948
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I saw a tip about this over on Ted Husted's site, but I have not tried it out:

"Struts Tip #17 - Don't settle for html:error"
http://husted.com/struts/tips/017.html

- Brent
 
Brent Sterling
Ranch Hand
Posts: 948
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
BTW, this is also posted over on jguru, and there is some discussion of an error in Ted's example.

http://www.jguru.com/faq/view.jsp?EID=1029711

- Brent
 
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Also, look for the heading "Displaying Error Messages" in the link below:

http://struts.apache.org/struts-doc-1.2.x/api/org/apache/struts/taglib/html/package-summary.html#package_description
 
alex alex
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Brent

I had a look through the ted husted pages i saw these before I posted, but this does not detail with the validator framewrok it is for those situations when you have actionerrors. I am trying to do it for the validator framewrok before it gets to the action class

Thakns
 
Brent Sterling
Ranch Hand
Posts: 948
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I guess I do not understand why Ted Husted's method (once corrected to add the html:errors entries) or the section "Displaying Error Messages" in the link that Merrill posted would not work with the Validator Framework.

- Brent
 
Won't you be my neighbor? - Fred Rogers. tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic