Exception:According to TLD or attribute directive in tag file, attribute value does not accept any expression
Exception:According to TLD or attribute directive in tag file, attribute value does not accept any expression應(yīng)用部署運(yùn)行的時(shí)候出現(xiàn)JSP異常, 發(fā)生在使用JSTL庫(kù)的時(shí)候: According to TLD or attribute directive in tag file, attribute value does not accept any expressions, 可能是因?yàn)槭褂昧薐SP2.0版本, 同時(shí)又沒(méi)有使用JSTL core庫(kù)的備用版本(RT庫(kù)), 以下有兩種處理方法:
1. 修改web.xml.
改為2.3版本的
<web-app>
2. 使用JSTL core RT庫(kù)
JSTL core庫(kù)的有兩種taglib偽指令, 其中RT庫(kù)即是依賴于JSP傳統(tǒng)的請(qǐng)求時(shí)屬性值, 而不是依賴于EL來(lái)實(shí)現(xiàn)(稱為EL庫(kù).JSP2.0將支持EL)
JSP中使用<%@ taglib uri=http://java.sun.com/jstl/core prefix="c"%>在2.3版本都可以,在2.4就不行了, 難道是版本不兼容嗎?
只要將
改為
就沒(méi)有問(wèn)題了
posted on 2007-03-08 20:52 Ecko 閱讀(2289) 評(píng)論(2) 編輯 收藏