在tomcat+jbuilder下使用Struts,出错!
在工程目录下新建一个jsp1.jsp页面(选上Struts1.0中的Struts-bean,Struts-html)
jsp1的代码为:
<%@ page contentType="text/html; charset=gb2312"%>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<%@ taglib uri="/WEB-INF/struts-template.tld" prefix="template" %>
<html:html locale="true">
<head>
<html:base/>
<title>
<bean:message key="index.title"/></title>
</head>
<h1>创建一个用户</h1>
<html:errors/>
<html:form action="jsp1.do" method="get">
username:<html:test property="username" /><br/>
userpass:<html:test property="userpass" /><br/>
<html:submit property="submit" />
</html:form>
</body>
</html:html>
其中struts-config的配置为:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE struts-config PUBLIC "-//Apache Software Foundation//DTD Struts Configuration 1.0//EN" "http://jakarta.apache.org/struts/dtds/struts-config_1_0.dtd">
<struts-config>
<global-forwards>
<forward name="jsp1" path="/jsp1.jsp"/>
</global-forwards>
<action-mappings>
<action path="/jsp1"
input="/jsp1.jsp">
</action>
</action-mappings>
</struts-config>
运行jsp1.jsp,但出现“"jsp2.jsp": org.apache.jasper.JasperException: No such tag test in the tag library imported with prefix html”,请问,怎么解决?????