note 50379 added to wrappers.http

From: Date: Sat, 26 Feb 2005 05:59:46 +0000
Subject: note 50379 added to wrappers.http
Groups: php.notes 
Request: Send a blank email to php-notes+get-85576@lists.php.net to get a copy of this message
Using stream_get_meta_data() and print_r() to display the actual HTTP meta data headers : <?php echo "<pre>"; $url = "http://www.osde.info/"; $fp = fopen($url, 'r'); foreach(stream_get_meta_data($fp) as $response) { print_r($response); } fclose($fp); echo "</pre>"; ?> Output: Array ( [0] => HTTP/1.1 200 OK [1] => Date: Sat, 26 Feb 2005 05:29:08 GMT [2] => Server: Apache [3] => Last-Modified: Sun, 14 Nov 2004 23:24:18 GMT [4] => ETag: "2ec334-6ae-4197e922" [5] => Accept-Ranges: bytes [6] => Content-Length: 1710 [7] => Connection: close [8] => Content-Type: text/html ) HTTPsocket17101 ---- Manual Page -- http://www.php.net/manual/en/wrappers.http.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+50379 Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+50379&report=yes&reason=added+to+the+manual Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+50379&report=yes&reason=bad+code Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+50379&report=yes&reason=spam Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+50379&report=yes&reason=useless Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+50379&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+50379&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#85576) next »