Prentice Hall and Sun Microsystems. Personal use only; do not redistribute.
4.3 HTTP 1.1 Request Headers
101
Content Type
Although this header is usually used in responses from the server, it can 
also be part of client requests when the client attaches a document as 
the 
POST
 data or when making 
PUT
 requests. You can access this header 
with the shorthand 
getContentType
 method of 
HttpServletRequest
.
Cookie
This header is used to return cookies to servers that previously sent 
them to the browser. For details, see Chapter 8 (Handling Cookies). 
Technically, 
Cookie
 is not part of HTTP 1.1. It was originally a 
Netscape extension but is now very widely supported, including in both 
Netscape and Internet Explorer.
Expect
This rarely used header lets the client tell the server what kinds of 
behaviors it expects. The one standard value for this header, 
100 con 
tinue
, is sent by a browser that will be sending an attached document 
and wants to know if the server will accept it. The server should send a 
status code of either 100 (
Continue
) or 417 (
Expectation Failed
) in 
such a case. For more details on HTTP status codes, see Chapter 6 
(Generating the Server Response: HTTP Status Codes).
From
This header gives the e mail address of the person responsible for the 
HTTP request. Browsers do not send this header, but Web spiders 
(robots) often set it as a courtesy to help identify the source of server 
overloading or repeated improper requests.
Host
Browsers are required to specify this header, which indicates the host 
and port as given in the original URL. Due to request forwarding and 
machines that have multiple hostnames, it is quite possible that the 
server could not otherwise determine this information. This header is 
not new in HTTP 1.1, but in HTTP 1.0 it was optional, not required.
Second edition of this book: www.coreservlets.com; Sequel: www.moreservlets.com.
Servlet and JSP training courses by book's author: courses.coreservlets.com.






footer




 

 

 

 

 Home | About Us | Network | Services | Support | FAQ | Control Panel | Order Online | Sitemap | Contact

jsp web hosting

 

Our partners: PHP: Hypertext Preprocessor Best Web Hosting Java Web Hosting Jsp Web Hosting Cheapest Web Hosting

Visionwebhosting.net Business web hosting division of Web Design Plus. All rights reserved