ch17: Content Negotiation and Transcoding
1. Content-Negotiation Techniques
Client-driven
Server-driven
Transparent
2. Client-Driven Negotiation
The easiest thing for a server to do when it receives a client request is to send back a response listing the available pages and let the client decide which one it wants to see.
Increased latency and annoyance of multiple requests per page.
Requires multiple URLs.
3. Server-Driven Negotiation
Content-Negotiation Headers:
Header | Description |
Accept | Used to tell the server what media types are okay to send |
Accept-Language | Used to tell the server that languages are okay to send |
Accept-Charset | Used to tell the server what charsets are okay to send |
Accept-Encoding | Used to tell the server what encodings are okay to send |
Last updated