When I do a <form:errors path="*"/>
my errors are always shown in a random order.
Now I was wondering how I could display them in a set order.
What I mean with random is: fields: f开发者_JAVA技巧ield1, field2, field3 output 1: field2, field1, field3 output 2: field 3, field 2, field 1 ...
This is not an exact fit to your question. You can order your errors if you specify the desired path value instead of "*". For example,
<form:errors path="field1"/>
<form:errors path="field2"/>
<form:errors path="field3"/>
精彩评论