I have a custom error logic written in 404.jsp. In this file I have wrote a response.sendRedirect(< My Custom Error Page>);
When landing on the customized error page, the response status is 200. I have a separate template for my 404 page. I tried to set <% response.setStatus(404);%> in the content.jsp of that template but still the response status is 200.
I need this customized error page to return a 404 status.
Thanks in advance !!
Views
Replies
Total Likes
See this KB:
https://helpx.adobe.com/experience-manager/kb/CustomErrorHandling.html
It talks about how to create custom scripts or error handlers that render different HTTP errors .
Views
Replies
Total Likes
Hi Scott,
I already overlayed /apps/sling/servlet/errorhandler and also the I turned off CQ WCM Debug Filter. I believe because of response.sendRedirect("/404page.html"), it is throwing status as 200. I am trying to throw status as 404 even If I am doing a redirect to my custom page.
As mentioned above I tried to reset the status too on my custom error page "404page.html" but it didn't work.
Views
Replies
Total Likes