I am working on Magento 2.
if ($this->getRequest()->isAjax()) {
$layout = $this->_layout;
}
How can I print or debug value of $layout
in above code ??
debuglogmagento2
I am working on Magento 2.
if ($this->getRequest()->isAjax()) {
$layout = $this->_layout;
}
How can I print or debug value of $layout
in above code ??
Best Answer
On top of what Ashar Riaz said, you can also use the
debug
method from\Psr\Log\LoggerInterface
:IIRC, the values will be logged under
var/log/debug.log