Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:31624 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 86060 invoked by uid 1010); 16 Aug 2007 12:22:24 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 86041 invoked from network); 16 Aug 2007 12:22:24 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 16 Aug 2007 12:22:24 -0000 Authentication-Results: pb1.pair.com header.from=hannes.magnusson@gmail.com; sender-id=pass; domainkeys=bad Authentication-Results: pb1.pair.com smtp.mail=hannes.magnusson@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.198.188 as permitted sender) DomainKey-Status: bad X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: hannes.magnusson@gmail.com X-Host-Fingerprint: 209.85.198.188 rv-out-0910.google.com Received: from [209.85.198.188] ([209.85.198.188:14799] helo=rv-out-0910.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id CA/91-06865-F7144C64 for ; Thu, 16 Aug 2007 08:22:23 -0400 Received: by rv-out-0910.google.com with SMTP id k15so200682rvb for ; Thu, 16 Aug 2007 05:22:19 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=Uf7lQEXMa8UGUCZ3LJ6aSqLOC+VZewS69K8e7ULUEMc8Aj+H0wmyinlJYL+HONOqnQVVr4pk5nhVBFHdzb+Ji3KzPGVn0ylYCSTDK7FxV5FW1Giqf+AE8/ezFDAvv701WnL9Tmyx7xS04O4+0d7/35pX7wbGbeQ6oeq4yE+V/WY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=nTco0d7SkwzjCHySKQL82KJz4KbYFygNQcmmcIxGIu/yeOo1el+i6Mb9ta0cn73hz1V981IPOblvxBScB66AExeb+PO8NGm5McTRGSOgay3XKuLBrsnwvhNGLyweNUezGsvOJ8StTSgIoRiwL7IGAVHSJjgq3kwZKNMA5EXqDbQ= Received: by 10.141.41.12 with SMTP id t12mr662163rvj.1187266936223; Thu, 16 Aug 2007 05:22:16 -0700 (PDT) Received: by 10.140.252.15 with HTTP; Thu, 16 Aug 2007 05:22:16 -0700 (PDT) Message-ID: <7f3ed2c30708160522m2cecc5b7wb2dc6c1a7cb1ba25@mail.gmail.com> Date: Thu, 16 Aug 2007 14:22:16 +0200 To: "PHP Development" In-Reply-To: <7f3ed2c30708150759p56b99921v1f589dcc107e743d@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <7f3ed2c30708150759p56b99921v1f589dcc107e743d@mail.gmail.com> Subject: Re: [PATCH] New parameter for in_array() & array_search() From: hannes.magnusson@gmail.com ("Hannes Magnusson") On 8/15/07, Hannes Magnusson wrote: > Hi all > > Attached* is a patch introducing a new parameter to in_array() and > array_search() which will set the internal pointer to the first > location of $needle in the $haystack (granted that $needle exists > within the $haystack). Or should we maybe create two new functions? bool array_seek_value(&$array, mixed $value [, bool $strict=false]); bool array_seek_key(&$array, integer/string $key); -Hannes