use-default-template configuration tag does not work

谁说胖子不能爱 提交于 2019-12-11 00:40:04

问题


I've created simple "Hello world" portlet and just added

<use-default-template>true</use-default-template>

to the portlet section of liferay-portlet.xml file.

Portlet stopped to work with the following exception in the log

11:29:03,973 ERROR [PortletLocalServiceImpl:656] com.liferay.portal.kernel.xml.DocumentException: Error on line 13 of document : The content of element type "portlet" must match "(portlet-name,icon?,............ and so on

The name of my tag is present here.

Why is this? Is this tag obsolete or something?

Thanks.


回答1:


The problem is the order of the tags on the liferay-portlet.xml. You should put the tags on the right order following the "spec" (DTD).




回答2:


Yes problem with DTD order only.

You can can see some good articles of liferay portal.

http://www.exceptionhandle.com/portal/category/portals-2



来源:https://stackoverflow.com/questions/7953174/use-default-template-configuration-tag-does-not-work

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!