Magento 1 zend log code example
Example: magento2 zend log
<?php
$writer = new \Zend\Log\Writer\Stream(BP . '/var/log/MYLOGFILE.log');
$logger = new \Zend\Log\Logger();
$logger->addWriter($writer);
$logger->info('Your text message');
?>
<?php
$writer = new \Zend\Log\Writer\Stream(BP . '/var/log/MYLOGFILE.log');
$logger = new \Zend\Log\Logger();
$logger->addWriter($writer);
$logger->info('Your text message');
?>