Skip to content

Instantly share code, notes, and snippets.

@joegreen88
Created April 19, 2013 10:15
Show Gist options
  • Save joegreen88/5419429 to your computer and use it in GitHub Desktop.
Save joegreen88/5419429 to your computer and use it in GitHub Desktop.
Filter empty rows out of a Smrtr_DataGrid instance.
<?php
$grid = $grid->filterRows(function($key, $label, $row){
return array_reduce($row, function(&$result, $item){
$result = is_null($item) ? $result : true;
}, false);
});
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment