Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:25733 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 77806 invoked by uid 1010); 16 Sep 2006 15:11:13 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 77791 invoked from network); 16 Sep 2006 15:11:13 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 16 Sep 2006 15:11:13 -0000 Authentication-Results: pb1.pair.com header.from=pierre.php@gmail.com; sender-id=pass; domainkeys=good Authentication-Results: pb1.pair.com smtp.mail=pierre.php@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 64.233.182.190 as permitted sender) DomainKey-Status: good X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: pierre.php@gmail.com X-Host-Fingerprint: 64.233.182.190 nf-out-0910.google.com Linux 2.4/2.6 Received: from [64.233.182.190] ([64.233.182.190:36714] helo=nf-out-0910.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 59/EB-23155-1141C054 for ; Sat, 16 Sep 2006 11:11:13 -0400 Received: by nf-out-0910.google.com with SMTP id y25so2876226nfb for ; Sat, 16 Sep 2006 08:11:10 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=OcqcIYe8iLcPRu+BosxIFvpmPbKA4B+eXFnS3yrdS0GnyUxoqGZIL3tYsXzEJDadjKUaq8flUK3GagMlH42vGLBn+3WvHjLnd7JjlNDuQN7viDEgS5mYM1/lGcDu1gGjcsFlmbxodi012xe7vZys2FnV65585ZyX1Y+zq5XFDhw= Received: by 10.78.123.5 with SMTP id v5mr2406230huc; Sat, 16 Sep 2006 08:11:10 -0700 (PDT) Received: by 10.78.137.6 with HTTP; Sat, 16 Sep 2006 08:11:10 -0700 (PDT) Message-ID: Date: Sat, 16 Sep 2006 17:11:10 +0200 To: "Christian Schneider" Cc: internals@lists.php.net, derick@php.net, rasmus@php.net, ilia@prohost.org In-Reply-To: <450C0E3F.8070005@cschneid.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20060916125431.42e9a5dd@pierre-u64> <450C02B3.10103@cschneid.com> <450C0E3F.8070005@cschneid.com> Subject: Re: ext/filter, Final API proposal From: pierre.php@gmail.com (Pierre) Hello, On 9/16/06, Christian Schneider wrote: > Pierre wrote: > > It always returns an array when FILTER_FLAG_ARRAY is given. Even when > > the input value was a scalar. It spares yet another is_array/isset > > test. And it accepts only scalar by default or when FILTER_FLAG_SCALAR > > is given. > > Makes sense but the example shows: Again, this proposal is not based on the current neither on the examples in the manual (I did not check them recently, there is maybe mistakes). > a) This is a documentation bug > b) FILTER_FLAG_ARRAY is 'inherited' from the previous arg ('component') > c) The values are always returned as array > > My favourite one being a) :-) This is what this proposal says too, so I consider that you agree :) > > It uses INPUT_REQUEST (which is not yet implemented, and will not be > > for 5.2.0). One should rely only on the constants not their values :) > > I agree wholeheartedly but I think it would be nice to have > INPUT_REQUEST for 5.2.0 already. Or are you advising people to use Sadly no, it will not be in 5.2.0. We do not have the time, the resources and the required tests to implement it before 5.2.0. > $myinputs = input_get_args(INPUT_GET, $args, $data) + > input_get_args(INPUT_POST, $args, $data) [ + ... ]; > > as work-around for now? Just wondering... It will be array_merge(G,P,C,S) then, but this is not the goal of this thread :-) > > However, the point was about the API changes (signature, way to call > > them, etc...). I suppose you like it? > > Yes, the API looks great as far as I can tell. Danke! --Pierre