I have an associative array with a whole pile of true/false values.
I am trying to remove all keys where the values are false.
So if the array is
array(
'key1' => true,
'key2' => false,
'key3' => false,
'key4' => true
);
I want to end up with
array(
'key1' => true,
'key4' => true
);
How would I do this?
array_filter()