Unable to load tag handler class "org.apache.struts2.views.jsp.ui.FormTag" for tag "s:form"
If I run my code in NetbeansIDE it shows the following error:
org.apache.jasper.JasperException: /InvestorConfirm.jsp(53,12) PWC6032: Unable to load tag handler class "org.apache.struts2.views.jsp.ui开发者_JS百科.FormTag" for tag "s:form"
I downloaded the struts2-core-2.0.11.jar file, and searched for "struts2.views.jsp.ui.FormTag", but couldn't find that class.
How can I resolve this issue?
To install Struts2, just put the Struts2 JAR file (and its dependencies) in the /WEB-INF/lib
.
Do not extract the JAR file and spread all its loose contents (TLD files?) over the classpath as some poor online tutorials (with roseindia.net as topper) may suggest. This exception namely indicates that the TLD file is been found in the classpath, but that the associated tag class is missing in the classpath. This can only happen if you did so. Cleanup the classpath and redo according Apache's own Struts2 docs.
This can by the way in theory also be caused by having different Struts2 versions in the classpath, but this is unlikely as the package of FormTag
has not been changed among versions.
精彩评论