Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi,
I am using hook_block_view_alter in a custom module, but it does not effect the translated blocks on our site.
For example, I would expect the code below to hide all the blocks on our site. However, only the blocks in our primary language are hidden. The translated blocks are unaffected. Is that expected behavior? Seems odd that it works that way.
function MY_MODULE_block_view_alter(&$data, $block) {
$data["subject"] = "";
$data["content"] = " ";
}
Comments