get_headers
Description
array get_headers ( string url [, int format] )get_headers() returns an array with the headers sent by the server in response to a HTTP request.
Parameters
urlThe target URL.
formatIf the optional
formatparameter is set to 1, get_headers() parses the response and sets the array's keys.
ChangeLog
| Version | Description |
|---|---|
| 5.1.3 | This function now uses the default stream context, which can be set/changed with the stream_context_get_default() function. |
Examples
