解决"taglib definition not consistent with specification version"

来源:互联网 发布:sap采购订单数据库 编辑:程序博客网 时间:2024/05/29 15:25

1. 问题描述

      从tomcat 6 迁移到tomcat 7 时,运行web项目时出现"taglib definition not consistent with specification version"

      从上面可以看出, 这是taglib的定义不符合规范版本的原因引起来的

      下图可看出错误的地方:


2. 解决方法

    修改web.xml, 如下:

修改前:

<taglib>    <taglib-uri>/custom</taglib-uri>    <taglib-location>/WEB-INF/tld/custom.tld</taglib-location></taglib>

修改后:

<!-- 自定义标签 --><jsp-config>    <taglib><taglib-uri>/custom</taglib-uri><taglib-location>/WEB-INF/tld/custom.tld</taglib-location>    </taglib></jsp-config>


阅读全文
1 0
原创粉丝点击