how to detect area when adding a block?
Permalink
I want to be able to know the areaHandle for the area I'm attempting to add a block to, from within that block's controller.
I put this in the block's add() function:
with no luck. I can access other generic block properties, but not the Area handle.
Specifically, I want to check the areaHandle against a list of scrapbook handles (which I already have).
I put this in the block's add() function:
$b = Block::getByID($this->bID); $this->set('areaHandle', $b->getAreaHandle());
with no luck. I can access other generic block properties, but not the Area handle.
Specifically, I want to check the areaHandle against a list of scrapbook handles (which I already have).
Thank you.