Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:53717 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 94740 invoked from network); 1 Jul 2011 10:08:14 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 1 Jul 2011 10:08:14 -0000 Authentication-Results: pb1.pair.com smtp.mail=hannes.magnusson@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=hannes.magnusson@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.218.42 as permitted sender) X-PHP-List-Original-Sender: hannes.magnusson@gmail.com X-Host-Fingerprint: 209.85.218.42 mail-yi0-f42.google.com Received: from [209.85.218.42] ([209.85.218.42:45729] helo=mail-yi0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id AF/20-26454-E8C9D0E4 for ; Fri, 01 Jul 2011 06:08:14 -0400 Received: by yih10 with SMTP id 10so1459543yih.29 for ; Fri, 01 Jul 2011 03:08:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=z8+abBr86Z2lVJJNyAZn7rIyOOeoY+Lj5QXhlELD1ps=; b=Zo5BvWloGtVYB8QbII8+fXpJst2b9zA074j3OpJx12RcR+BXwIg7vSmElsOovTAq+6 plpmEJ3eut06LiigBW2MX4T8wqjSlA7/TaBSYQ6NSTts1K1srUAN2YBr9AIlrzKi/20s 8Yrdq+g1PIuw4LzGKiKED55/sPRO0XD1uqArQ= MIME-Version: 1.0 Received: by 10.236.185.169 with SMTP id u29mr4080828yhm.108.1309514890919; Fri, 01 Jul 2011 03:08:10 -0700 (PDT) Received: by 10.146.210.3 with HTTP; Fri, 1 Jul 2011 03:08:10 -0700 (PDT) In-Reply-To: <2535D0F7-57FE-4BA9-8815-13884F5C6EE7@bitextender.com> References: <4E0CE015.80503@no-surprises.co.uk> <4E0CEAC5.3070800@sugarcrm.com> <4E0CEBDC.6050206@no-surprises.co.uk> <4E0D06C9.2030102@sugarcrm.com> <2535D0F7-57FE-4BA9-8815-13884F5C6EE7@bitextender.com> Date: Fri, 1 Jul 2011 12:08:10 +0200 Message-ID: To: =?UTF-8?B?RGF2aWQgWsO8bGtl?= Cc: Stas Malyshev , Michael Maclean , PHP internals Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [PHP-DEV] Improvements to HTTP stream metadata From: hannes.magnusson@gmail.com (Hannes Magnusson) On Fri, Jul 1, 2011 at 10:18, David Z=C3=BClke wrote: > On 01.07.2011, at 01:29, Stas Malyshev wrote: > >> Hi! >> >> On 6/30/11 2:34 PM, Michael Maclean wrote: >>> The same data also ends up in the bizarre $http_response_headers var >>> that gets spontaneously created in local scope - I've wondered about ho= w >>> good that is to do. >> >> This thing is indeed bizzare. I wonder if anybody uses it and why it was= done this way... > > I've used it before... IIRC, it was because that var gets set on older PH= P versions even if the HTTP response is an error (in which case the stream = is destroyed and you can't get the metadata anymore either; newer versions = have the "ignore_errors" context option for that). > I use it extensively. Its nearly the only way to get the headers from file_get_contents() for example. -Hannes