-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not found page must return HTTP 404 #71
Comments
|
I don't understand. Assume there is some event or condition when LUYA redirects to predefined 404 page, i.e. "no route" or "model not found". Why we can't just display predefined page content and throw 404 instead of redirect to it? Could you point me where redirect happens? |
nick-denry, the problem can be solved like this
in views/error/index.php:
|
@nick-denry Maybe i have an idea how to fix this problem and output the content from the page instead of redirecting, this would fix problem 1 and 2. @dven84 Thanks for providing us your solution, this is indeed also a good idea to cover all kind of exceptions! Fix: |
Hi!
I'm pretty sure that custom "not found" page should return HTTP 404 to be not indexed by SE. Now it's return HTTP 200.
It's also better not to use 301 redirect to "not found" page, but display it's content with 404 code.
Otherwise it will be redirect 301 to HTTP 404 (301 -> 404).
The text was updated successfully, but these errors were encountered: