weblogic运行时报jsp编译异常,着急再线等谢谢。
运行环境是:AIX,weblogic10.3,JDK1.6
该应用在tomcat和websphere上运行都没问题。先在weblogic下运行报错信息如下:
weblogic.servlet.jsp.CompilationException: Failed to compile JSP /UI/mobilebank/infoselect/userInfo/userInfoList.jsp
userInfoList.jsp:10:5: Invalid tag library.
<%@ taglib uri="/WEB-INF/tld/struts-bean.tld" prefix="bean" %>
^----^
userInfoList.jsp:10:5: No tag library could be found with this URI. Possible causes could be that the URI is incorrect, or that there were errors during parsing of the .tld file.
userInfoList.jsp:11:5: Invalid tag library.
<%@ taglib uri="/WEB-INF/tld/struts-html.tld" prefix="html" %>
^----^
userInfoList.jsp:11:5: No tag library could be found with this URI. Possible causes could be that the URI is incorrect, or that there were errors during parsing of the .tld file.
<%@ taglib uri="/WEB-INF/tld/struts-html.tld" prefix="html" %>
..............
at weblogic.servlet.jsp.JavelinxJSPStub.compilePage(JavelinxJSPStub.java:328)
at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:237)
at weblogic.servlet.jsp.JspStub.prepareServlet(JspStub.java:182)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:235)
at weblogic.servlet.internal.ServletStubImpl.onAddToMapException(ServletStubImpl.java:408)
Truncated. see log file for complete stacktrace
jsp页面中代码如下:
<%@ taglib uri="/WEB-INF/tld/struts-bean.tld" prefix="bean" %>
<%@ taglib uri="/WEB-INF/tld/struts-html.tld" prefix="html" %>
<%@ taglib uri="/WEB-INF/tld/struts-logic.tld" prefix="logic" %>
<%@ taglib uri="/WEB-INF/tld/struts-nested.tld" prefix="nested" %>
<%@ taglib uri="/WEB-INF/tld/struts-tiles.tld" prefix="tiles" %>
web.xml中配置如下:
<jsp-config>
<taglib>
<taglib-uri>http://jakarta.apache.org/struts/tags-bean</taglib-uri>
<taglib-location>/WEB-INF/tld/struts-bean.tld</taglib-location>
</taglib>
........
</jsp-config>
tld文件在对应目录下确定已经存在。
weblogic.xml中配置如下参数:
<container-descriptor>
<prefer-web-inf-classes>true</prefer-web-inf-classes>
</container-descriptor>