skip to Main Content

php bin/magento setup:di:compile Errors

when i run php bin/magento setup:di:compile on cmd this error will occur: Compilation was started. Plugin list generation... 8/9 [========================>---] 88% 10 mins 392.0 MiB In ErrorHandler.php line 61: Warning: file_put_contents(C:/xampp/htdocs/magento/generated/metadata/primary|global|plugin-list.php): failed to open stream: No such file or directory…

VIEW QUESTION

Get product name and price from product collection – Magento

I am trying to get product(s) name and price from product collection for that I have created a custom script for test. $bootstrap = Bootstrap::create(BP, $_SERVER); $objectManager = $bootstrap->getObjectManager(); $state = $objectManager->get('MagentoFrameworkAppState'); $state->setAreaCode('adminhtml'); $collection = $objectManager->create('MagentoCatalogModelResourceModelProductCollectionFactory')->create(); try { echo $collection->addAttributeToSelect(['name','sku'])->getSelect();…

VIEW QUESTION
Back To Top
Search