Tuesday, 19 August 2014

HTTP Status Codes

HTTP Status Codes
Hello Developers, I came across Some Http Errors, I got some data about Http Errors that I am sharing with you guys.
HTTP, Hypertext Transfer Protocol, is the method by which clients (i.e. you) and servers communicate. When someone clicks a link, types in a URL or submits out a form, their browser sends a request to a server for information. It might be asking for a page, or sending data, but either way, that is called an HTTP Request. When a server receives that request, it sends back an HTTP Response, with information for the client. Usually, this is invisible, though I'm sure you've seen one of the very common Response codes - 404, indicating a page was not found. There are a fair few more status codes sent by servers, and the following is a list of the current ones in HTTP 1.1, along with an explanation of their meanings.

Client Error

400 - Bad Request
a status code of 400 indicates that the server did not understand the request due to bad syntax.

401 - Unauthorized
a 401 status code indicates that before a resource can be accessed, the client must be authorised by the server.

403 - Forbidden
a 403 status code indicates that the client cannot access the requested resource. That might mean that the wrong username and password were sent in the request, or that the permissions on the server do not allow what was being asked.

404 - Not found
the best known of them all, the 404 status code indicates that the requested resource was not found at the URL given, and the server has no idea how long for.

408 - Request Timeout
A 408 status code means that the client did not produce a request quickly enough. A server is set to only wait a certain amount of time for responses from clients, and a 408 status code indicates that time has passed.

414 - Request-URI Too Long
The 414 status code indicates the URL requested by the client was longer than it can process.


Server Error

500 - Internal Server Error
A 500 status code (all too often seen by Perl programmers) indicates that the server encountered something it didn't expect and was unable to complete the request.

501 - Not Implemented
The 501 status code indicates that the server does not support all that is needed for the request to be completed.

502 - Bad Gateway
A 502 status code indicates that a server, while acting as a proxy, received a response from a server further upstream that it judged invalid.

503 - Service Unavailable
A 503 status code is most often seen on extremely busy servers, and it indicates that the server was unable to complete the request due to a server overload.

504 - Gateway Timeout
A 504 status code is returned when a server acting as a proxy has waited too long for a response from a server further upstream.

505 - HTTP Version Not Supported
A 505 status code is returned when the HTTP version indicated in the request is no supported. The response should indicate which HTTP versions are supported.

No comments:

Post a Comment