Fórum
Set display order for page in new community
khomeini syahril, modificado 14 Anos atrás.
Set display order for page in new community
Junior Member Postagens: 56 Data de Entrada: 16/10/08 Postagens Recentes
Hi all,
i'm creating a community, that has several pages: page a, page b, etc
i m trying to set the display order as i want, ex: page a, page c, page d, and then page b
all i could do is to set it manually from admin account, but it doesnt apply to the community of a new instance i created
any idea?
Best Regards,
Khomeini
i'm creating a community, that has several pages: page a, page b, etc
i m trying to set the display order as i want, ex: page a, page c, page d, and then page b
all i could do is to set it manually from admin account, but it doesnt apply to the community of a new instance i created
any idea?
Best Regards,
Khomeini
Jonas Yuan, modificado 14 Anos atrás.
RE: Set display order for page in new community
Liferay Master Postagens: 993 Data de Entrada: 27/04/07 Postagens Recentes
You can do it by customization: adding order by default in JSP files.
There are, at least, two options:
1) override JSP files of Manage-Pages in the EXT;
2) override JSP files of Manage-Pages in the Plugin SDK via hooks;
Hope that it helps
Thanks
Jonas Yuan
-----------------
Liferay Books
Liferay Portal 5.2/5.3 Systems Development
Liferay Portal 4.4/5.0 Enterprise Intranets
There are, at least, two options:
1) override JSP files of Manage-Pages in the EXT;
2) override JSP files of Manage-Pages in the Plugin SDK via hooks;
Hope that it helps
Thanks
Jonas Yuan
-----------------
Liferay Books
Liferay Portal 5.2/5.3 Systems Development
Liferay Portal 4.4/5.0 Enterprise Intranets
khomeini syahril, modificado 14 Anos atrás.
RE: Set display order for page in new community
Junior Member Postagens: 56 Data de Entrada: 16/10/08 Postagens Recentes
thanks Yuan, but could you be more specific? where i could edit the jsp and is there any example of how to create the order?
Best Regards,
Khomeini
Best Regards,
Khomeini
Jonas Yuan, modificado 14 Anos atrás.
RE: Set display order for page in new community
Liferay Master Postagens: 993 Data de Entrada: 27/04/07 Postagens Recentes
Hi Khomeini
Hope that the chapter 5 helps:
Extend the Communities portlet
Customize the Manage Pages portlet
Customize page management with more features
Use communities and layout pages efficiently
and hooks in chapter 10;
Experience the Control Panel
Build inter-portlet communication
Develop the Social Office theme
Add mail and chat portlets
Build Social Office with portlets
Hook portal properties and custom JSP files into Social Office
Use hooks more efficiently
You can find details at
Liferay Portal 5.2/5.3 Systems Development
Thanks
Jonas Yuan
----------------------
-----------------
Liferay Books
Liferay Portal 5.2/5.3 Systems Development
Liferay Portal 4.4/5.0 Enterprise Intranets
Hope that the chapter 5 helps:
Extend the Communities portlet
Customize the Manage Pages portlet
Customize page management with more features
Use communities and layout pages efficiently
and hooks in chapter 10;
Experience the Control Panel
Build inter-portlet communication
Develop the Social Office theme
Add mail and chat portlets
Build Social Office with portlets
Hook portal properties and custom JSP files into Social Office
Use hooks more efficiently
You can find details at
Liferay Portal 5.2/5.3 Systems Development
Thanks
Jonas Yuan
----------------------
-----------------
Liferay Books
Liferay Portal 5.2/5.3 Systems Development
Liferay Portal 4.4/5.0 Enterprise Intranets
khomeini syahril, modificado 14 Anos atrás.
RE: Set display order for page in new community
Junior Member Postagens: 56 Data de Entrada: 16/10/08 Postagens Recentes
Thank you Yuan,
the tutorial mentions about cloning "Manage Pages", but doesnt describe it well.. any other tutorial i could refer to?
Best Regards.
Khomeini
the tutorial mentions about cloning "Manage Pages", but doesnt describe it well.. any other tutorial i could refer to?
Best Regards.
Khomeini
Jonas Yuan, modificado 14 Anos atrás.
RE: Set display order for page in new community
Liferay Master Postagens: 993 Data de Entrada: 27/04/07 Postagens Recentes
Hi Khomeini,
The order of pages is specified by JavaScripts in JSP file edit_pages_children.jsp. You can use same mechanism and ovderride this JSP file (JavaScript ) in the Ext or in Plugins SDK via Hooks.
Hope it helps
Thanks
Jonas Yuan
-----------------
Liferay Books
Liferay Portal 5.2/5.3 Systems Development
Liferay Portal 4.4/5.0 Enterprise Intranets
The order of pages is specified by JavaScripts in JSP file edit_pages_children.jsp. You can use same mechanism and ovderride this JSP file (JavaScript ) in the Ext or in Plugins SDK via Hooks.
<c:when test="<%= tabs4.equals("display-order") %>">
<liferay-ui:error exception="<%= RequiredLayoutException.class %>">
<%
RequiredLayoutException rle = (RequiredLayoutException)errorException;
%>
<c:if test="<%= rle.getType() == RequiredLayoutException.AT_LEAST_ONE %>">
<liferay-ui:message key="you-must-have-at-least-one-page" />
</c:if>
<c:if test="<%= rle.getType() == RequiredLayoutException.FIRST_LAYOUT_TYPE %>">
<liferay-ui:message key="your-first-page-must-have-one-of-the-following-types" />: <%= PortalUtil.getFirstPageLayoutTypes(pageContext) %>
</c:if>
<c:if test="<%= rle.getType() == RequiredLayoutException.FIRST_LAYOUT_HIDDEN %>">
<liferay-ui:message key="your-first-page-must-not-be-hidden" />
</c:if>
</liferay-ui:error>
<liferay-ui:message key="set-the-display-order-of-child-pages" />
<br><br>
<table class="lfr-table">
<tbody><tr>
<td>
<select name="<portlet:namespace />layoutIdsBox" size="7">
<%
for (int i = 0; i < selLayoutChildren.size(); i++) {
Layout selLayoutChild = (Layout)selLayoutChildren.get(i);
%>
<option value="<%= selLayoutChild.getLayoutId() %>"><%= HtmlUtil.escape(selLayoutChild.getName(locale)) %></option>
<%
}
%>
</select>
</td>
<td valign="top">
<a href="javascript:Liferay.Util.reorder(document.<portlet:namespace />fm.<portlet:namespace />layoutIdsBox, 0);"><img border="0" height="16" hspace="0" src="<%= themeDisplay.getPathThemeImages() %>/arrows/02_up.png" vspace="2" width="16"></a><br>
<a href="javascript:Liferay.Util.reorder(document.<portlet:namespace />fm.<portlet:namespace />layoutIdsBox, 1);"><img border="0" height="16" hspace="0" src="<%= themeDisplay.getPathThemeImages() %>/arrows/02_down.png" vspace="2" width="16"></a><br>
<a href="javascript:<portlet:namespace />removePage(document.<portlet:namespace />fm.<portlet:namespace />layoutIdsBox);"><img border="0" height="16" hspace="0" src="<%= themeDisplay.getPathThemeImages() %>/arrows/02_x.png" vspace="2" width="16"></a><br>
</td>
</tr>
</tbody></table>
<br>
<input type="button" value="<liferay-ui:message key=" update-display-order">" onClick="<portlet:namespace />updateDisplayOrder();" />
</c:when>
Hope it helps
Thanks
Jonas Yuan
-----------------
Liferay Books
Liferay Portal 5.2/5.3 Systems Development
Liferay Portal 4.4/5.0 Enterprise Intranets