You are currently viewing the BOOK: Professional Jakarta Struts section of the Wrox p2p Programmer to Programmer discussion community. This is a community of more than 40,000 computer programmers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining our free Wrox p2p community you can post your own programming questions and respond to other programmers’ questions. Registered users also don't have to see the ads that are displayed to guests. Registration is fast, simple and absolutely free so please, join today!
Join today and post to win prizes! Post more to increase your chances of being Wrox’s top poster of the month.
I have two confusions in the <html:errors> tag-
In chapter 10 of the book professional Jakarta Struts 1.1, Listing 10.2 index.jsp, I think <html:errors> tag is incomplete.
I tried to run like this in my own application but it did'nt work.
what i know is when we write the <html:error> tag we mention the property name also:
<html:error property="symbol1"/>.-------------------------(3)
The reason this is required is when we make the ActionErrors object, we code like this:
ActionErrors err=new ActionErrors();
err.add("symbol1,new ActionError("keyname"));-----------(4)
So the "symbol1" in the add method is the value specified in the property at (3). So if we won't specify the property attribute then how will the <html:errors> will know about the error it refers to.
Secondly,In the book at page 169 below listing 10.3 its written that the "symbol1" at 4 is the value of the property of the <html:text> tag at (2).
But I have read that this "symbol1" at (4) corresponds to the value of the property at (3). I dont know what is correct. Plz help me in understanding the true concept.