You are here

function hook_social_core_block_visibility_path in Open Social 8.8

Same name and namespace in other branches
  1. 8.9 modules/social_features/social_core/social_core.api.php \hook_social_core_block_visibility_path()
  2. 10.3.x modules/social_features/social_core/social_core.api.php \hook_social_core_block_visibility_path()
  3. 10.0.x modules/social_features/social_core/social_core.api.php \hook_social_core_block_visibility_path()
  4. 10.1.x modules/social_features/social_core/social_core.api.php \hook_social_core_block_visibility_path()
  5. 10.2.x modules/social_features/social_core/social_core.api.php \hook_social_core_block_visibility_path()

Provide a method to alter array of blocks to hide.

This way we can also make sure that if another modules alter the same block that it will merge the array in one.

Return value

array Blocks in this array will be hidden from the associated paths.

1 function implements hook_social_core_block_visibility_path()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

social_event_social_core_block_visibility_path in modules/social_features/social_event/social_event.module
Alter the visibility of blocks coming from the event module.
1 invocation of hook_social_core_block_visibility_path()
social_core_block_access in modules/social_features/social_core/social_core.module
Hide blocks on extendable visibility path.

File

modules/social_features/social_core/social_core.api.php, line 26
Hooks provided by the Social core module.

Code

function hook_social_core_block_visibility_path() {
  $blocks = [
    'block_plugin_id_1' => [
      'path_1',
      'path_2',
    ],
    'block_plugin_id_2' => [
      'path_1',
      'path_2',
    ],
  ];
  return $blocks;
}