學(xué)習(xí)筆記

          Simple is beautiful.

          導(dǎo)航

          <2007年3月>
          25262728123
          45678910
          11121314151617
          18192021222324
          25262728293031
          1234567

          統(tǒng)計

          公告

          ...

          常用鏈接

          留言簿(1)

          隨筆分類(2)

          隨筆檔案(56)

          Weblog

          搜索

          最新評論

          評論排行榜

          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)用部署運行的時候出現(xiàn)JSP異常, 發(fā)生在使用JSTL庫的時候: According to TLD or attribute directive in tag file, attribute value does not accept any expressions, 可能是因為使用了JSP2.0版本, 同時又沒有使用JSTL core庫的備用版本(RT庫), 以下有兩種處理方法:

          1. 修改web.xml.

          <web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4">

          改為2.3版本的

          <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
          <web-app>

          2. 使用JSTL core RT庫

          JSTL core庫的有兩種taglib偽指令, 其中RT庫即是依賴于JSP傳統(tǒng)的請求時屬性值, 而不是依賴于EL來實現(xiàn)(稱為EL庫.JSP2.0將支持EL)

          JSP中使用<%@ taglib uri=http://java.sun.com/jstl/core prefix="c"%>在2.3版本都可以,在2.4就不行了, 難道是版本不兼容嗎?

          只要將

          <%@ taglib uri="http://java.sun.com/jstl/core" prefix="c"%>

          改為

          <%@ taglib uri=http://java.sun.com/jstl/core_rt prefix="c"%>

          就沒有問題了

          posted on 2007-03-08 20:52 Ecko 閱讀(2288) 評論(2)  編輯  收藏

          評論

          # re: Exception:According to TLD or attribute directive in tag file, attribute value does not accept any expression 2008-08-15 09:09 段布和

          謝~~~~~~~  回復(fù)  更多評論   

          # re: Exception:According to TLD or attribute directive in tag file, attribute value does not accept any expression 2009-05-15 00:04 謝鑫瑩

          問題解決了,謝謝你  回復(fù)  更多評論   


          只有注冊用戶登錄后才能發(fā)表評論。


          網(wǎng)站導(dǎo)航:
           
          主站蜘蛛池模板: 古田县| 西峡县| 昌邑市| 黄陵县| 新宁县| 景泰县| 桐庐县| 社旗县| 宾阳县| 凤庆县| 阿勒泰市| 平山县| 田林县| 孝昌县| 阿拉善左旗| 寿光市| 台州市| 内丘县| 焦作市| 呼伦贝尔市| 灵山县| 河曲县| 泸定县| 鄂托克旗| 比如县| 定南县| 永德县| 托克逊县| 新邵县| 盐边县| 民勤县| 奎屯市| 右玉县| 泰顺县| 蚌埠市| 惠安县| 金华市| 辛集市| 高雄市| 绥阳县| 周口市|