Reputation: 2195
I have defined some specific layout for my project in cakephp 3.But I don't need layout for certain functions.How to make it disable.Thanks in advance !
Upvotes: 1
Views: 3390
Reputation: 151
In CakePHP version >= 3.5 it is this function:
$this->viewBuilder()->enableAutoLayout(false);
Upvotes: 7
Reputation: 430
You can use this in your functions to remove the default layout :
$this->viewBuilder()->layout(false);
Upvotes: 5