Return proper status codes (404, 302) from client-side Single Page Application
reallfqq-nginx at yahoo.fr
Mon Aug 8 14:42:34 UTC 2016
Sending 404 allows providing body content, and displaying beautiful pages
is not restricted to 200. Thus, I do not get the 200 status sent to clients.
My suggestion would be sending the same HTTP status code to everyone,
choosing the most semantically correct in doing so.
We are drifting away from the topic, though.
You got some technical answers to your original question, the rest remains
out of scope.
On Mon, Aug 8, 2016 at 12:15 PM, msonntag <nginx-forum at forum.nginx.org>
> Hey B. R.,
> Thanks for your reply! I will have a look at the provided resources.
> As per your comment:
> > I find it strange you oppose HTTP 404 with 'a proper status code': 404 is
> a 'proper' status code.
> > I find it even stranger you want to lie to search engines crawlers about
> the existence of your resource.
> Maybe my wording was just misleading. Of course 404 is a "proper" status
> code and my posting was all about how to be able to return the appropriate
> code (404 in case the item does not exist) to the crawler instead of the
> that it will see if I just deliver the client application and show a "soft"
> 404 error – which is my current setup which I want to improve by checking
> the item's existence prior to delivering the response.
> Thanks again.
> Posted at Nginx Forum: https://forum.nginx.org/read.
> nginx mailing list
> nginx at nginx.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the nginx