Hi,
I'm not used to JSP and I'm getting some trouble to make a portlet
redirect the request to a JSP.
I've started with a very simple JSP:
--- view_01.jsp -------------------------------------
<%@ page contentType="text/html" %>
<%@ page pageEncoding="UTF-8" %>
<%@ page import="javax.portlet.*" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/portlet" prefix="portlet" %>
<portlet:defineObjects />
<form action="" method="post">
<table>
<!-- Row 1: is reserved for info -->
<tr>
<td colspan="3">Please, fill in the gaps with the appropiate
info...</td>
</tr>
<!-- Row 2: displays error messages -->
<% int flag = 1; %>
<% if (flag==1){ %>
<tr>
<td colspan="3">Show error message</td>
</tr>
<% } %>
<!-- Row 3+: display form fields -->
<tr>
<td>Status</td>
<td>Name</td>
<td>Value</td>
</tr>
<tr>
<td>Mandatory</td>
<td>username:</td>
<td><input type="text" /></td>
</tr>
</table>
</form>
---------------------------------------------------------
which is invoked from the following simple portlet:
--- portletA.java -------------------------------------
import javax.portlet.*;
import java.io.IOException;
public class AlfrescoRegistrationPortlet extends GenericPortlet{
private final String jsp_directory = "/jsp/portletA/";
public void doView(RenderRequest request, RenderResponse response)
throws IOException, PortletException{
PortletContext context = super.getPortletContext();
PortletRequestDispatcher rd =
context.getRequestDispatcher(jsp_directory + "view_01.jsp");
rd.include(request, response);
}
}
---------------------------------------------------------
My portlet application structure is:
jsp/
portletA/
view_01.jsp
WEB-INF
classes/
portletA.class
lib/
src/
tld/
Both jetspeed and tomcat (localhost) logs give no error trace...
But, though the portlet window is rendered, it renders no content... =/
Can anyone tell me what I'm doing wrong or if I'm missing some thing?
Thanks in advance.
Regards,
Enrique
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]