Foren

Home » Liferay Portal » English » 3. Development

Kombinierte Ansicht Flache Ansicht Baumansicht
Threads [ Zurück | Nächste ]
Ravi Kiran
ActionResponse.sendRedirect always shows 404 Error
14. April 2012 13:22
Antwort

Ravi Kiran

Rang: Junior Member

Nachrichten: 53

Eintrittsdatum: 7. April 2012

Neue Beiträge

The ActionResponse.sendRedirect always shows 404 Error


public class SatPortlet extends MVCPortlet {

public void addBook(ActionRequest request, ActionResponse response) throws IOException {

if(true)
{

response.sendRedirect("/html/satportlet/view2.jsp");
}

else
{
response.sendRedirect("/html/satportlet/error.jsp");
}

}
}




I have this pages present inside the docroot where this view.jsp is present .

<init-param>
<name>view-jsp</name>
<value>/html/satportlet/view.jsp</value>
</init-param>


Also present in tomcat webapps context path .

But every time it enters the MVCPortlet Action class and the condition is matched i displays this 404 .
Hitoshi Ozawa
RE: ActionResponse.sendRedirect always shows 404 Error
15. April 2012 04:17
Antwort

Hitoshi Ozawa

Rang: Liferay Legend

Nachrichten: 7949

Eintrittsdatum: 23. März 2010

Neue Beiträge

So do you have /html/satportlet/view2.jsp file? or am I missing the point of your question?
Ravi Kiran
RE: ActionResponse.sendRedirect always shows 404 Error
15. April 2012 11:12
Antwort

Ravi Kiran

Rang: Junior Member

Nachrichten: 53

Eintrittsdatum: 7. April 2012

Neue Beiträge

Yes i do have that and i checked that , and also added this action-url-redirect to true also . .