All Downloads are FREE. Search and download functionalities are using the official Maven repository.

META-INF.resources.wiki.error.jsp Maven / Gradle / Ivy

There is a newer version: 7.0.121
Show newest version
<%--
/**
 * SPDX-FileCopyrightText: (c) 2000 Liferay, Inc. https://liferay.com
 * SPDX-License-Identifier: LGPL-2.1-or-later OR LicenseRef-Liferay-DXP-EULA-2.0.0-2023-06
 */
--%>

<%@ include file="/wiki/init.jsp" %>

<%
WikiNode node = (WikiNode)request.getAttribute(WikiWebKeys.WIKI_NODE);

String title = ParamUtil.getString(request, "title");

boolean portletTitleBasedNavigation = GetterUtil.getBoolean(portletConfig.getInitParameter("portlet-title-based-navigation"));

if (portletTitleBasedNavigation) {
	portletDisplay.setShowBackIcon(true);

	String backURL = request.getHeader(HttpHeaders.REFERER);

	if (Validator.isNull(backURL)) {
		WikiURLHelper wikiURLHelper = new WikiURLHelper(wikiRequestHelper, renderResponse, wikiGroupServiceConfiguration);

		PortletURL backToViewPagesURL = wikiURLHelper.getBackToViewPagesURL(node);

		backURL = backToViewPagesURL.toString();
	}

	portletDisplay.setURLBack(backURL);

	renderResponse.setTitle(title);
}
%>


	







	<%
	long nodeId = ParamUtil.getLong(request, "nodeId");

	if ((nodeId == 0) && (node != null)) {
		nodeId = node.getNodeId();
	}

	PortletURL editPageURL = PortletURLBuilder.createRenderURL(
		renderResponse
	).setMVCRenderCommandName(
		"/wiki/edit_page"
	).setRedirect(
		currentURL
	).setParameter(
		"nodeId", nodeId
	).setParameter(
		"title", title
	).buildPortletURL();

	PortletURL searchURL = PortletURLBuilder.createRenderURL(
		renderResponse
	).setMVCRenderCommandName(
		"/wiki/search"
	).setRedirect(
		currentURL
	).setKeywords(
		title
	).setParameter(
		"nodeId", nodeId
	).buildPortletURL();
	%>

	
>
<% String taglibEditPage = "location.href = '" + editPageURL.toString() + "';"; %> <% String taglibSearch = "location.href = '" + searchURL.toString() + "';"; %>




© 2015 - 2024 Weber Informatics LLC | Privacy Policy