各位大哥,小弟发了四回帖子了!为什么没人解决!分都用完了!
csdn上的帖子我都翻遍了,也没解决!我在jbuilder运行jsp时总是提示这个错误:
URL: Unable to open location: Document not found on server
应该是那里的错误呀?因为刚学这个,所以还没掌握调试的技巧!
下面分别是jsp、xml、tld文件,都不长的!
jsp文件:
<%@ page contentType="text/html;charset=gb2312"%>
<%@ taglib uri="j2eeapp" prefix="tagdemo" %>
<HTML>
<HEAD>
<TITLE>TITLE>
</HEAD>
<BODY>
<tagdemo:simple/>
</BODY>
</HTML>
xml文件:
<?xml version="1.0" encoding="UTF-8"?>
<!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>
<taglib>
<taglib-uri>j2eeapp</taglib-uri>
<taglib-location>/WEB-INF/tlds/simple_tag.tld</taglib-location>
</taglib>
</web-app>
tld文件
<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE taglib
PUBLIC "-//Sun Microsystems, Inc.//DTD JSP Tag Library 1.2//EN"
"http://java.sun.com/j2ee/dtd/web-jsptaglibrary_1_2.dtd">
<taglib>
<tlib-version>1.0</tlib-version>
<jsp-version>1.2</jsp-version>
<short-name>simple_tag</short-name>
<uri>http://jakarta.apache.org/tomcat/example-taglib</uri>
<description> A simple tab library for the examples
</description>
<tag>
<name>simple</name>
<tag-class>SimpleTag</tag-class>
<body-content>empty</body-content>
<description>simple tag</description>
</tag>
</taglib>