如何解决'绝对uri:http://java.sun.com/portlet无法在web.xml或使用此应用程序部署的jar文件中解析'

问题描述 投票:0回答:1

当我将<%@ taglib uri='http://java.sun.com/portlet' prefix='portlet' %>添加到JSP文件时,我得到一个例外

依赖关系:

<dependency>
     <groupId>javax.portlet</groupId>
     <artifactId>portlet-api</artifactId>
     <version>3.0.1</version>
     <scope>provided</scope>
</dependency>

例外:

2019-04-10 11:28:17.573 ERROR [http-nio-8080-exec-6][PortletRequestDispatcherImpl:331] Unable to dispatch request: /jsp/departments.jsp(9,62) PWC6188: The absolute uri: http://java.sun.com/portlet cannot be resolved in either web.xml or the jar files deployed with this application
2019-04-10 11:28:17.574 ERROR [http-nio-8080-exec-6][PortletServlet:112] javax.portlet.PortletException: org.apache.jasper.JasperException: /jsp/departments.jsp(9,62) PWC6188: The absolute uri: http://java.sun.com/portlet cannot be resolved in either web.xml or the jar files deployed with this application
javax.portlet.PortletException: org.apache.jasper.JasperException: /jsp/departments.jsp(9,62) PWC6188: The absolute uri: http://java.sun.com/portlet cannot be resolved in either web.xml or the jar files deployed with this application
     at com.liferay.portlet.internal.PortletRequestDispatcherImpl.dispatch(PortletRequestDispatcherImpl.java:333)
     at com.liferay.portlet.internal.PortletRequestDispatcherImpl.include(PortletRequestDispatcherImpl.java:145)
java liferay-7
1个回答
0
投票

将<%@ taglib uri ='http://java.sun.com/portlet'prefix ='portlet'%>更改为http://java.sun.com/portlet_2_0'prefix ='portlet'%>

© www.soinside.com 2019 - 2024. All rights reserved.