how to get product id in magento2 code example
Example: magento load product by id
$productId = 20;
$product = Mage::getModel('catalog/product')->load($productId);
$productId = 20;
$product = Mage::getModel('catalog/product')->load($productId);