Skip to content

magento man

How to validate the shipping methods in Magento 2 according to the custom checkbox created in shipping address for Local Pick-up

I have created a checkbox in the shipping form for local pick-up option. If user checks it, shipping address get populated as the store address. Now I want to show, the custom created, shipping method for Local Pick-up only if… Read More »How to validate the shipping methods in Magento 2 according to the custom checkbox created in shipping address for Local Pick-up

Total cart Weight how to show order summary in magento 2.4.6

How can We achieve this? We get total weight of products of cart in Magento 2 by MagentoCheckoutModelCart class With objectManager $objectManager = MagentoFrameworkAppObjectManager::getInstance(); $cart = $objectManager->get(‘MagentoCheckoutModelCart’); $items = $cart->getQuote()->getAllItems(); $weight = 0; foreach($items as $item) { $weight += ($item->getWeight()… Read More »Total cart Weight how to show order summary in magento 2.4.6

Magento 2 : Class “ZendMvcControllerAbstractActionController” not found

I use Magento 2.4.6-p5 Getting this error on compilation: There is an error in htdocs/setup/src/Magento/Setup/Controller/AddDatabase.php at line: 11 Class “ZendMvcControllerAbstractActionController” not found#0 htdocs/vendor/composer/ClassLoader.php(444): include() I removed the generated folder and cleared the cache, did not help. I also downloaded the… Read More »Magento 2 : Class “ZendMvcControllerAbstractActionController” not found

foreach() argument must be of type array|object, null given in ShippingAssignmentProcessor.php

I have upgraded Magento from 2.4.3 to 2.4.6-p4, and now I’m getting this exception. Anybody else familiar with this? [2024-05-09T13:13:54.211477+00:00] main.CRITICAL: Exception: Warning: foreach() argument must be of type array|object, null given in /data/web/magento2/vendor/magento/module-quote/Model/Quote/ShippingAssignment/ShippingAssignmentProcessor.php on line 89 in /data/web/magento2/vendor/magento/framework/App/ErrorHandler.php:62 Stack… Read More »foreach() argument must be of type array|object, null given in ShippingAssignmentProcessor.php