Get containing Area handle in block type controller.php
Permalink 1 user found helpfulFatal error: Cannot access protected property BlockView::$block
Any ideas?
But it sounds like you want it from the view anyway, which this should work:
$areaName = $this->block->getAreaHandle();
if ($this->block->isBlockInStack()) { $area_handle = $this->block->c->getStackName(); } else { $area_handle = $this->block->getAreaHandle(); }
Please let me know if that works :)
John