Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error in my taglib <%@ taglib prefix="portlet" uri="http://java.sun.com/portlet_2_0"%>

When I developed my portlet and when i wrote my jsp page I used:

<%@ taglib prefix="portlet" uri="http://java.sun.com/portlet_2_0"%>

but eclipse show me an error telling me that it cannot find the tag lib descriptor for http://java.sun.com/portlet_2_0.

How can I resolve this issue wihtout using tld files ?

like image 549
Wael Avatar asked Dec 21 '12 14:12

Wael


1 Answers

In my case, I am using Liferay Portal, so in order to avoid this error I changed:

<%@ taglib uri="http://java.sun.com/portlet_2_0"% prefix="portlet">


to

<%@ taglib uri="/WEB-INF/tld/liferay-portlet.tld" prefix="portlet" %>


and in file "WEB-INF/liferay-plugin-package.properties"; I added this line

portal-dependency-tlds=/WEB-INF/tld/liferay-portlet.tld

which is suggested by a Liferay staff (Link)

like image 128
Linh Lino Avatar answered Nov 16 '22 03:11

Linh Lino