function yamaps_block_info in Yandex.Maps 7
Implements hook_block_info().
File
- inc/
yamaps.block.inc, line 11 - Yandex Maps blocks configuration.
Code
function yamaps_block_info() {
$blocks[YAMAPS_DEFAULT_BLOCK_DELTA] = [
'info' => t('Yandex Map #1'),
'cache' => DRUPAL_NO_CACHE,
];
$blocks_amount = variable_get('yamaps_blocks_amount', YAMAPS_DEFAULT_BLOCK_AMOUNT);
for ($block_number = 2; $block_number <= $blocks_amount; $block_number++) {
$blocks[YAMAPS_DEFAULT_BLOCK_DELTA . '_' . $block_number] = [
'info' => t('Yandex Map #!block_number', [
'!block_number' => $block_number,
]),
'cache' => DRUPAL_NO_CACHE,
];
}
return $blocks;
}