EL表达式取值
转自: http://hi.baidu.com/fevelen/item/5b0484510c059ad8d48bacb9 Jstl是sun的标准taglib库,Jstl是标签库和el语言的结合。 el表达式的隐含对象pageScope,requestScope,sessionScope,applicationScope,比如${hello}语句首先会从pageScope开始逐个查找scope中的属性,指定域对象语句为${requestScope.hello} 属性值 :${hello} 对象值 姓名:${user.username} 年龄:${user.age} 所属组:${user.group.name} map集合 假设Action中保存map集合: Map mapvalue=new HashMap(); mapvalue.put(“key1”,”值1”); mapvalue.put(“key2”,”值2”); request.setAttribute(“mapvalue”,mapvalue); ${mapvalue.key1} 数组 假设Action中有数组 Char[] char={“1”.”2”}; request.setAttribute(“char”,char); ${char[1]} 数组中的对象 User[] users=new User[10]; for