Re: PHP and named groups in regex/PCRE

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Mar 6, 2009 at 19:12, Daevid Vincent <daevid@xxxxxxxxxx> wrote:
> A friend was showing off his regex-fu and the virtues of "named groups"
> and how great Python is, knowing that PHP had to be equally as good
> (since it uses the same PCRE libraries), we whipped up this little test.
> So now us PHP folks can enjoy the same benefit! :-)

    Appending to Daevid's post, a snippet from the note he posted
about this a little bit ago (it will appear on the manual entry soon):

    Note that you actually get the named group as well as the
numerical key value too, so if you do use them, and you're counting
array elements, be aware that your array might be bigger than you
initially expect it to be.

-- 
</Daniel P. Brown>
daniel.brown@xxxxxxxxxxxx || danbrown@xxxxxxx
http://www.parasane.net/ || http://www.pilotpig.net/
50% Off All Shared Hosting Plans at PilotPig: Use Coupon DOW10000

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux