Skip to content

magento man

Magento2 keeps loading without displaying the home page or the admin

My site keeps loading without displaying the home page or the admin. var/log/debug.log: main.DEBUG: cache_invalidate: {“method”:”GET”,”url”:”https://website.com/pct-eveil-tle-cde.html”,”invalidateInfo”:{“identifier”:”interception”}} [] main.DEBUG: cache_invalidate: {“method”:”GET”,”url”:”http://website.com/robots.txt”,”invalidateInfo”:{“identifier”:”interception”}} [] pub/error_log: PHP Deprecated: Return type of phpseclib_mcrypt_filter::filter($in, $out, &$consumed, $closing) should either be compatible with php_user_filter::filter($in, $out, &$consumed, bool… Read More »Magento2 keeps loading without displaying the home page or the admin

How i get current product name by product collection?

How i get current product name in sendEmail funtion if (isset($result) && $result) { $this->emailHelper->sendEmail(‘Product’, $productName); } And this is my full code. <?php declare(strict_types=1); namespace custommoduleScheduleContentNotifierPlugin; use MagentoCatalogStagingModelProductApplier; use custommoduleScheduleContentNotifierHelperEmail; use MagentoCatalogModelResourceModelProductCollection; use MagentoStagingApiUpdateRepositoryInterface; class PluginProductApplier { protected $emailHelper;… Read More »How i get current product name by product collection?

char column in db_schema.xml

https://developer.adobe.com/commerce/php/development/components/declarative-schema/configuration/#column-subnode I didn’t find the char type (only varchar) in the column section but in the length section char is present. I tried to use char myself like so: <column xsi:type=”char” name=”hash” nullable=”false” length=”32″ comment=”MD5″/> and it seems to properly… Read More »char column in db_schema.xml

Magento 2.4.6 – Set the sort of the attributes in a programmatically created configurable product by setUsedProductAttributeIds()

I’m successfully import from a CSV file a massive number of SIMPLE products. Than I created the CONFIGURABLE products and assigned the simples by $configurableproduct_load->setCanSaveConfigurableAttributes(true); $configurableproduct_load->getTypeInstance()->setUsedProductAttributeIds(array(258,267,178), $configurableproduct_load); $configurableAttributesData = $configurableproduct_load->getTypeInstance()->getConfigurableAttributesAsArray($configurableproduct_load); $configurableproduct_load->setConfigurableAttributesData($configurableAttributesData); $configurableproduct_load->setAssociatedProductIds($associatedProductIds); $configurableproduct_load->save(); where 258, 267, 178 are the attributes… Read More »Magento 2.4.6 – Set the sort of the attributes in a programmatically created configurable product by setUsedProductAttributeIds()