Query: http_parse_headers
OS: php
Section: 3
Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar
HTTP_PARSE_HEADERS(3) 1 HTTP_PARSE_HEADERS(3) http_parse_headers - Parse HTTP headersSYNOPSISarray http_parse_headers (string $header)DESCRIPTIONParses HTTP headers into an associative array.PARAMETERSo $header - string containing HTTP headersRETURN VALUESReturns an array on success or FALSE on failure.EXAMPLESExample #1 Using http_parse_headers(3) <?php $headers = "content-type: text/html; charset=UTF-8 ". "Server: Funky/1.0 ". "Set-Cookie: foo=bar ". "Set-Cookie: baz=quux ". "Folded: works too "; print_r(http_parse_headers($headers)); ?> The above example will output: Array ( [Content-Type] => text/html; charset=UTF-8 [Server] => Funky/1.0 [Set-Cookie] => Array ( [0] => foo=bar [1] => baz=quux ) [Folded] => works too )SEE ALSOhttp_parse_message(3), http_parse_cookie(3). PHP Documentation Group HTTP_PARSE_HEADERS(3)
Related Man Pages |
---|
http::headers::util(3) - osx |
http::headers::util(3) - suse |
apache_response_headers(3) - php |
http_parse_params(3) - php |
nsapi_request_headers(3) - php |
Similar Topics in the Unix Linux Community |
---|
Rules for Homework & Coursework Questions Forum |
Forum Video Tutorial: How to Use Code Tags |
Status of UNIX.COM Forum Transformation |
Denial Of Service Attack Update |