function global_filter_get_filters_for_block in Views Global Filter 8
Same name and namespace in other branches
- 7 global_filter.blocks.inc \global_filter_get_filters_for_block()
Return an array of names of the filters inside the block by the given id.
Parameters
int $block_number: a positive integer: 1, 2, 3...
Return value
array array of filter names
7 calls to global_filter_get_filters_for_block()
- global_filter_active_filter_names in ./
global_filter.module - Returns a list of all filter names or only those visible on the current page.
- global_filter_block_info in ./
global_filter.blocks.inc - Implements hook_block_info().
- global_filter_block_view in ./
global_filter.blocks.inc - Implements hook_block_view().
- global_filter_finalise_form in ./
global_filter.widgets.inc - Complete the form.
- global_filter_submission_form in ./
global_filter.widgets.inc - Creates the global selector widgets, e.g. drop-down, radio-boxes, links...
File
- ./
global_filter.blocks.inc, line 485 - global_filter.block.inc
Code
function global_filter_get_filters_for_block($block_number) {
$filter_parameters = global_filter_get_parameter(NULL);
foreach ($filter_parameters as $key => $filter) {
if (drupal_substr($filter['block'], -1) != $block_number) {
unset($filter_parameters[$key]);
}
}
return $filter_parameters;
}