Eclipse/Tomcat忘记了自定义标签?

Pre*_*ete 5 eclipse jsp tomcat custom-tags

我在Windows 7 64位上使用Eclipse Kepler和Tomcat 7.

如果我清理项目并重新启动服务器,一切都很好.但是,如果我工作几分钟...就像编辑一个jsp ... Tomcat barfs以下...

它抱怨丢失的标签是页面布局的标签.没有其他令人兴奋的东西,除了它有一些jspf包括和内容页面也称为其他标签.但同样,没有什么令人兴奋

我不知道我是如何导致这一点的,因为事情编译并且最初运行良好.但是Tomcat似乎失去了对标签类的追踪.

如果我清理项目,它会恢复工作一段时间......

有任何想法吗?谢谢

HTTP Status 500 - Unable to compile class for JSP:

type Exception report

message Unable to compile class for JSP:

description The server encountered an internal error that prevented it from fulfilling this request.

exception

org.apache.jasper.JasperException: Unable to compile class for JSP: 

An error occurred at line: 33 in the jsp file: /folder/page.jsp
org.apache.jsp.tag.weblayout_002dmain_tag cannot be resolved to a type
30: 
31: 
32: 
33: <tags:layout-main>
34:     <jsp:attribute name="title">page</jsp:attribute>
35:     <jsp:attribute name="section">user</jsp:attribute>
36:     <jsp:attribute name="handle">page</jsp:attribute>


An error occurred at line: 33 in the jsp file: /folder/page.jsp
org.apache.jsp.tag.weblayout_002dmain_tag cannot be resolved to a type
30: 
31: 
32: 
33: <tags:layout-main>
34:     <jsp:attribute name="title">page</jsp:attribute>
35:     <jsp:attribute name="section">user</jsp:attribute>
36:     <jsp:attribute name="handle">page</jsp:attribute>


An error occurred at line: 106 in the jsp file: /folder/page.jsp
org.apache.jsp.tag.webrating_tag cannot be resolved to a type
103:            <div class="page clearfix">
104:                <div class="title">
105:                    <h3>${page.name}</h3>
106:                    <br><tags:rating value="${3}"/>                         
107:                    <br>${page.type}
108:                </div>
109:                <div class="hours">
Run Code Online (Sandbox Code Playgroud)

Mr.*_*. P 0

尝试以下任何一项,它应该有效

  1. 将 jar 复制到WEB-INF/lib/目录中,然后重新启动 Web 容器

  2. 尝试

    <%@ page language="java" import="Pkgname.className.*" %>
    
    Run Code Online (Sandbox Code Playgroud)

例如

    <%@ page language="java" import="org.apache.jsp.tag.webrating" %>
Run Code Online (Sandbox Code Playgroud)
  1. 清理项目并重新启动服务器