use-default-template configuration tag does not wo

2019-07-15 11:59发布

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.

2条回答
三岁会撩人
2楼-- · 2019-07-15 12:39

Yes problem with DTD order only.

You can can see some good articles of liferay portal.

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

查看更多
看我几分像从前
3楼-- · 2019-07-15 12:40

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).

查看更多
登录 后发表回答