portlet的doview只是拿到session对象,然后传递了一个参数
protected void doView(RenderRequest request, RenderResponse response) throws PortletException, IOException {
PortletContext context=getPortletContext();
response.setContentType("text/html");
PortletRequestDispatcher rd=null;
rd=context.getRequestDispatcher("/show/list.jsp");
PortletSession session=request.getPortletSession();
        session.setAttribute("session_data","abc");
rd.include(request, response);
            }
而jsp页面却拿不到,session_data是null。
<table border="1" bgcolor="cccccc" width="500" cellpadding="3" cellspacing="0">
<tr>name</tr>
<tr>${session_data}</tr>
</table>
要是我用了request.setAttribute()这个方法,jsp可以拿得到。