What is the purpose of the 'Cache-Control' HTTP header?
A. To specify caching policies for the resource
B. To set the language of the content
C. To control the format of the response
D. To authenticate the user
Answer: Option A
Solution (By JKSSB Mock Tests)
The Cache-Control header is used to define caching directives such as max-age, no-cache, and private, controlling how and for how long the resource can be cached.
Explanation:
Web servers (like Apache or Nginx) listen for HTTP requests to deliver HTML and web assets to browsers, while database servers (like MySQL or Oracle) store and query raw tabular data collections.
What does a '405 Method Not Allowed' HTTP status code return imply about a client browser's interaction with a web application?
A.The input security certificate has an expired authorization date.
B.The requested URL address path has changed its location permanently.
C.The web server facility has completely crashed down.
D.The server recognizes the request method, but the specific target resource does not support that method (e.g., trying to POST to a read-only static text file).
Explanation:
An HTTP 405 error occurs when the requested resource is configured to reject the specific HTTP method used (such as a browser attempting a POST action on a static page designed only to accept GET requests).
No comments yet. Be the first to start the discussion!