[opencms-dev] forward
Ben Hurwitz
bhurwitz at m-Qube.com
Wed May 24 23:17:26 CEST 2006
I raised the question, and the answer I got seemed to work, despite the
fact that CmsToolDialog and CmsToolManager are geared toward the
workplace.
You need to use org.opencms.workplace.tools.CmsToolManager's
jspForwardPage() method. Here is an example JSP that does forwarding:
<%@ page language="java"%>
<%@ page import="org.opencms.workplace.*"%>
<%@ page import="org.opencms.workplace.tools.*"%>
<%@ page import="java.util.*"%>
<% cms.init(pageContext, request, response); %>
<%
String parentFolder =
cms.getCmsObject().getRequestContext().getFolderUri();
CmsToolDialog dialog = new CmsToolDialog(cms);
dialog.getToolManager().jspForwardPage(dialog, parentFolder +
"forwardPage.jsp", new HashMap());
%>
The map you pass in is used for parameters, so you can populate it if
you need to access them.
Ben
-----Original Message-----
From: opencms-dev-bounces at opencms.org
[mailto:opencms-dev-bounces at opencms.org] On Behalf Of Robert Petermeier
Sent: Monday, May 22, 2006 5:05 AM
To: The OpenCms mailing list
Subject: Re: [opencms-dev] forward
Atanas,
Atanas Atanasov schrieb:
> How to forward from one jsp page to another?
> Tag <jsp:forward page="...." /> not work correctly
there is a method
CmsRequestUtil.forward(String, HttpServletRequest, HttpServletResponse)
which, unfortunately, appears to be broken in (there was a thread about
this recently). As a possible but not very nice workaround you might use
a redirect and append request parameters to the URL as GET parameters.
Robert
_______________________________________________
This mail is sent to you from the opencms-dev mailing list
To change your list options, or to unsubscribe from the list, please
visit
http://lists.opencms.org/mailman/listinfo/opencms-dev
More information about the opencms-dev
mailing list