You are here

function hook_views_filters_selective_sort_alter in Views Selective Filters 7

Alter the order of a filter options here.

Parameters

array $oids: An array of options for a filter.

object $handler: An instance of the views_handler_filter_selective class.

1 invocation of hook_views_filters_selective_sort_alter()
views_handler_filter_selective::get_oids in ./views_handler_filter_selective.inc
Get list of options for current view, only at runtime.

File

./views_filters_selective.api.php, line 16
API documentation for the Views Selective Exposed Filters module.

Code

function hook_views_filters_selective_sort_alter(array &$oids, $handler) {
  if ($handler->view->name == 'SOME_VIEW_NAME' && $handler->real_field == 'SOME_FIELD_NAME') {

    // Re-order $oids here.
  }
}