1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
   |  
<% java.util.List presidents = new java.util.ArrayList(); %>
 
<% java.util.Map president = new java.util.HashMap(); %>
<% president.put("name", "George Washington"); %>
<% president.put("nickname", "Father of His Country"); %>
<% president.put("term", "1789-1797"); %>
<% presidents.add(president); %>
 
<% request.setAttribute("pres", presidents); %>
 
<body>
	<ec:table 
		items="pres"
		action="${pageContext.request.contextPath}/extremeComponents.jsp"
		imagePath="${pageContext.request.contextPath}/images/table/*.gif"
		title="Presidents"
		width="60%"
		rowsDisplayed="5"
		>
		<ec:row>
			<ec:column property="name"/>
			<ec:column property="nickname"/>
			<ec:column property="term"/>
		</ec:row>
	</ec:table>
</body> |