Issue 104: how to use jsp taglibs
Status:  Invalid
Owner: ----
Closed:  May 2008
Reported by renrenta...@gmail.com, May 20, 2008
What steps will reproduce the problem?

1. controller:
request.setAttribute("items", items);

2.jsp:
<form name="presidentsForm"
	action="${pageContext.request.contextPath}/jmesa.action">
	<jmesa:tableFacade id="tag" items="${items}" var="bean">
		<jmesa:htmlTable width="600px">
			<jmesa:htmlRow>
				<jmesa:htmlColumn property="id" 
title="id" />
				<jmesa:htmlColumn property="key" 
title="key" />
				<jmesa:htmlColumn property="value" 
title="value" />
			</jmesa:htmlRow>
		</jmesa:htmlTable>
	</jmesa:tableFacade>
</form>
 
3. org.apache.jasper.JasperException: Unable to convert string "${items}" 
to class "java.util.Collection" for attribute
 "items": Property Editor not registered with the PropertyEditorManager


What is the expected output? What do you see instead?

I want jmesa to render the output pages,but I have not seen it.

What version of the product are you using? On what operating system?

jmesa 2.3.1 java 1.5 windows xp

Please provide any additional information below.

 
May 20, 2008
#1 extremec...@gmail.com
Judging from the error it is saying that the EL expression is not expanding. Can you
print out the list just using a regular JSP EL expression loop on the page?

Expanding EL expressions is something that the container does. This is the first
error of this kind I have heard so I would have to say something in your setup is not
working. What servlet container (Tomcat, Websphere, etc...) do you use?
May 21, 2008
#2 renrenta...@gmail.com
hi,thanks for helping, I use Tomcat 5.5 and struts 2,I tried to use java script to 
get data from request,code below:

	List<TestBean> list = (List<TestBean>)request.getAttribute("datas");

	for (TestBean a: list)
	{
		System.out.println(a.getKey());
	}

it works,but the error 

org.apache.jasper.JasperException: Unable to convert string "${items}" 
to class "java.util.Collection" for attribute
 "items": Property Editor not registered with the PropertyEditorManager

appeared,what's the problem?what's wrong ??
May 23, 2008
#3 extremec...@gmail.com
I probably should have asked right away, but are you able to run the examples? If so
then it is something in your application setup. 

What you have is very basic and running well. I'm not sure how to even help you debug
it other than try and see if you can print out your bean using straight JSP EL
expressions.

If you still need help we should move this discussion over to the groups to see if
anyone else has any ideas.
Status: Invalid