| Author |
error in ArrayList in JSP
|
Mimi Tam
Ranch Hand
Joined: Mar 05, 2010
Posts: 121
|
|
Dear all,
I could not find exactly what I need to know in order to fix this problem. Hope someone can help me out.
In my Controller (names in code below changed for proprietary reasons):
In my JSP:
I got compile errors on my JSP:
Invalid attribute (items)
Invalid attribute (value)
....
Questions:
Do I need to do .setAttributes for item, if so, how?
Is this the right way to pass an ArrayList to the View (from ModelAndView)?
Why am I getting these errors and how can they be solved?
Thanks very much in advance.
|
 |
Lorand Komaromi
Ranch Hand
Joined: Oct 08, 2009
Posts: 276
|
|
Did you add the JSTL taglib directive to your JSP?
Are the JSTL jars in WEB-INF/lib? Your code looks fine to me...
|
OCJP 6 (93%)
|
 |
Mimi Tam
Ranch Hand
Joined: Mar 05, 2010
Posts: 121
|
|
Thank you Lorand.
I have this as a separate file (include.jsp):
and I included it my JSPs that referenced these taglibs:
but its not working
Any other ideas would be greatly appreciated. Thanks!!!
|
 |
Christophe Verré
Sheriff
Joined: Nov 24, 2005
Posts: 14672
|
|
First, replace
with .
See this FAQ to understand why. (but this is probably not going to solve your problem)
|
[My Blog]
All roads lead to JavaRanch
|
 |
 |
|
|
subject: error in ArrayList in JSP
|
|
|