would like PageNotFoundException which returns a 404 and generalized http error code returning base exception class -------------------------------------------------------------------------------------------------------------------
Key: WICKET-785 URL: https://issues.apache.org/jira/browse/WICKET-785 Project: Wicket Issue Type: New Feature Components: wicket Affects Versions: 1.4.0-alpha Reporter: Jonathan Locke instead of having to do this manually, it would be nice if we had a simple PageNotFoundException we could throw to return a 404 for a page. getRequestCycle().setRequestTarget(EmptyRequestTarget.getInstance()); try { getWebRequestCycle().getWebResponse().getHttpServletResponse().sendError(404); } catch (IOException e) { e.printStackTrace(); } it might also be quite nice to have a more general base class for the 404 exception that can return other errors like 403, etc. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.