How do you remove the lines that have empty elements from a multidimensional-array in PHP?
For instance, from:
1: a, b, c, d
2: d, _, b, a
3: a, b, _, _
I would iterate through a foreach loop myself something like:
$array)
{
$empty_flag = false;
foreach ($array as $key => $val)
{
if ($val == '')
{
$empty_flag = true;
}
}
if ($empty_flag == true)
{
unset($md_array[$key]);
}
}
?>
There's almost definitely a more efficient way of doing this so anyone else who has a better solution feel free to let me and Alex know.