zoukankan      html  css  js  c++  java
  • 关于jstl taglib的错误 Can not find the tag library descriptor for “http://java.sun.com/jstl/core”

    在查了N个帖子之后,决定记录一下关于jstl taglib的配置方法。

    首先我遇到的错误是:

    Can not find the tag library descriptor for “http://java.sun.com/jstl/core”

    按照查到的资料,JSTL taglib需要jstl.jar来支持。在1.0和1.1版本的时候,还需要standard.jar来配合。但从1.2版本开始,jar文件名字变成了jstl-1.2.jar,也不再需要standard.jar了。另外,servlet 版本需要2.4以上。所以正确的做法是把jstl-1.2.jar放到WEB-INF/lib里面就可以了。或者通过maven来配置,如下:

    <dependency>
        <groupId>javax.servlet</groupId>
        <artifactId>jstl</artifactId>
        <version>1.2</version>
    </dependency>


    然后在运行时看到这个错误:

    org.apache.jasper.JasperException: The absolute uri: http://java.sun.com/jstl/core cannot be resolved in either web.xml or the jar files deployed with this application
    这是uri错误。在jstl.jar版本1.0和1.1的时候,名字里面没有“jsp”。但是1.2版本后变成了http://java.sun.com/jsp/jstl/core了,改好后解决。


  • 相关阅读:
    测试用例
    SQL/My sql
    测试报告
    postman
    Linux环境搭建及命令
    jQuery EasyUI API 中文文档 树表格(TreeGrid)
    MYSQL学习心得(十) 自定义存储过程和函数
    webBrowser
    ASP.NET MVC5+EF6+EasyUI 后台管理系统(1)前言与目录
    vim括号操作(转)
  • 原文地址:https://www.cnblogs.com/pekkle/p/6568693.html
Copyright © 2011-2022 走看看