Re: How I get the index value using Hash::extract() on this array

2012-12-05 Thread lowpass
Whoops! That should be: $keys = array_keys(Hash::remove($your_data, '{n}[check=0]')); On Wed, Dec 5, 2012 at 1:46 PM, Lucas Simon Rodrigues Magalhaes wrote: > Hi, > > I solved it using this logic: > > foreach ($arrayCheckBoxCheked as $idBilling => $value) { > > if ($value['check'] == 0) { > unse

Re: How I get the index value using Hash::extract() on this array

2012-12-05 Thread Lucas Simon Rodrigues Magalhaes
Hi, I solved it using this logic: foreach ($arrayCheckBoxCheked as $idBilling => $value) { if ($value['check'] == 0) { unset($arrayCheckBoxCheked[$idBilling]); } } I will try implement you solution. thank you!! Em quarta-feira, 5 de dezembro de 2012 15h49min21s UTC-2, cricket escreveu: > >

Re: How I get the index value using Hash::extract() on this array

2012-12-05 Thread lowpass
This should do it: $keys = array_keys(Hash::remove('{n}[check=0]')); On Wed, Dec 5, 2012 at 11:50 AM, Lucas Simon Rodrigues Magalhaes wrote: > Array( > [168] => Array > ( > [check] => 0 > ) > > [169] => Array > ( > [check] => 1 > ) > > [170] => Array > ( >

How I get the index value using Hash::extract() on this array

2012-12-05 Thread Lucas Simon Rodrigues Magalhaes
Array( [168] => Array ( [check] => 0 ) [169] => Array ( [check] => 1 ) [170] => Array ( [check] => 1 ) [171] => Array ( [check] => 1 ) [172] => Array ( [check] => 0 ) ); I try it, $a = Hash::extract($arrayCheckBox