Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:23064 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 57043 invoked by uid 1010); 1 May 2006 14:18:04 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 57027 invoked from network); 1 May 2006 14:18:04 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 1 May 2006 14:18:04 -0000 X-Host-Fingerprint: 217.79.190.163 r163.red.fastwebserver.de Received: from ([217.79.190.163:7318] helo=localhost.localdomain) by pb1.pair.com (ecelerity 2.0 beta r(6323M)) with SMTP id D5/6D-18514-B9816544 for ; Mon, 01 May 2006 10:18:03 -0400 To: internals@lists.php.net Date: Mon, 1 May 2006 16:17:54 +0200 Message-ID: <20060501161754.64020950@localhost.localdomain> Reply-To: pierre.php@gmail.com X-Newsreader: Sylpheed-Claws 2.1.0 (GTK+ 2.8.6; x86_64-unknown-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Posted-By: 217.79.190.163 Subject: ext/filter, add input_get_args, support of scalar or array result From: pierre.php@gmail.com (Pierre) Hello, Here is another patch for ext/filter (I still wait the answer for the other one about decimal separator...). This patchs adds the input_get_args function. This functions allows to fetch all input you like in one call using a definition array. It is also more flexible than input_get as you can mix options and flags for one value. I put a small example here: http://pecl.php.net/~pierre/filter_input_get_args_example.phps and the patch: http://pecl.php.net/~pierre/patch_filter_input_get_args.txt I voluntary duplicate codes from input_get. It behaves slightly differently and I like to keep them separate as long as the patch is not accepted. I also like to change input_get behaviors. We actually have no way to know if a variable does not exists or is invalid. Both return NULL. I like to return false when a variable does not fit the condition and NULL when it does not exist. Is it fine? If yes, I'll provide another patch. Cheers, -- Pierre