Day: October 19, 2016

magento 2

Magento 2 add static Block

To update cms static block for particular store programmatically you can use following code $objectManager = \Magento\Framework\App\ObjectManager::getInstance(); $identifier = 'block_identifier'; $store_id = 2; try { $block = $objectManager->create('Magento\Cms\Model\Block'); $block->setStoreId($store_id); // store for block you want to update $block->load($identifier, 'identifier'); $block->setIdentifier($identifier);...