function hook_alpha_pagination_numbers_alter in Views Alpha Pagination 7.2
Same name and namespace in other branches
- 8.2 alpha_pagination.api.php \hook_alpha_pagination_numbers_alter()
Allows modules and themes to alter the numbers array prior to rendering.
Note: Do not use range(); always be explicit when defining numbers. This is necessary as you cannot rely on the server language to construct proper numerical characters.
Parameters
array $numbers: An associative array of key/value pairs, passed by reference. Each key is a corresponding langcode and its value is an indexed array of numbers for that langcode.
\views_handler_area_alpha_pagination $view: The View instance.
See also
\views_handler_area_alpha_pagination::getNumbers()
1 invocation of hook_alpha_pagination_numbers_alter()
- AlphaPagination::getNumbers in src/
AlphaPagination.php - Retrieves numeric characters, based on langcode.
File
- ./
alpha_pagination.api.php, line 45 - The API for the Views Alpha Pagination module.
Code
function hook_alpha_pagination_numbers_alter(array &$numbers, \views_handler_area_alpha_pagination $view) {
// Remove 0 from the list.
array_shift($numbers['en']);
}