What is content negotiation?

Content negotiation is the technique described in the HTTP Transfer Protocol (HTTP) specification, which allows a remote client to make a more specific web server request. The method gives the server the ability to host multiple types of files, documents in different languages ​​and others, each with different quality levels. These separate selections are hosted as the only link marked with its uniform source identifier (URI), and aim to provide more usable content if available on the server. URI specifics such as the location of the file to be delivered, the file name and its type are elaborated after the content is arranged. This allows different parts of the content to sit in different places, such as all files for a particular language organized under the folder of this language on the server.

The idea of ​​content negotiation is that the web server gives the best possible content for any user agent or web browser. Can supply certain types of image files or other content to clientswho are able to support them. This is useful when hosting multiple versions of the file to support multiple viewing platforms such as mobile devices.

In order to do it all, HTTP describes two methods of content negotiation and also suggests the ability to combine them. One method is the server -based negotiation. With this method, the server is best to decide what to add, based on any logic that is given and what content is available. .

There is some problems with the server controlled -controlled content. The server does not know how to respond to all possible requirements, so they must be estimated based on the logic given for decision -making. He cannot know whether the web browser is running on a mobile device, or whether the required document is intended to send directly to the printer if not told. There are also problems with the protection of personal data, in the fact that the method controlled by serialVerem expects a request to send it to the user's information.

The second method is known as negotiating the content controlled by the agent. Here the user submits a server request and sends the server back a list of available alternatives if it exists. The selection is either automatically made, based on available browser preferences or platforms, or manually in the form of the options listed in HTML. The primary disadvantage of the agent managed by the agent are more server requirements for the best possible content. However, if the proxy server stores a cache sales application on a server that uses negotiations based on agents, it will be able to supply suitable contents all users for proxy via a single cache request.

IN OTHER LANGUAGES

Was this article helpful? Thanks for the feedback Thanks for the feedback

How can we help? How can we help?