Skip to content

Instantly share code, notes, and snippets.

@nhart
Created September 3, 2013 23:19
Show Gist options
  • Save nhart/6430897 to your computer and use it in GitHub Desktop.
Save nhart/6430897 to your computer and use it in GitHub Desktop.
a way to sort islandora solr facets
$results_sorted = array();
foreach ($results as $key => $row) {
$results_sorted[$key] = $row['bucket'];
}
$results_sorted = array_map('strtolower', $results_sorted);
array_multisort($results_sorted, SORT_ASC, $results);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment