I have a custom block in magento 2.4 where I retrieve a image List namespace PcmagasFirstModuleBlockMyList; use MagentoCatalogModelProductRepository; use MagentoFrameworkApiSearchCriteriaBuilder; use MagentoFrameworkViewElementTemplate; class MyList extends Template { private ProductRepository $productRepository; private SearchCriteriaBuilder $searchCriteriaBuilder; public function __construct( TemplateContext $context, ProductRepository $productRepository, SearchCriteriaBuilder $searchCriteriaBuilder, array $data = [] ) { parent::__construct($context, $data); […]
Magento2
I have problem with so old version Magento (customer didn’t moved for a whole time). I can login in admin panel, but nothing can press. No one button, any action, nothing. I tried this one: increased memory_limit = 128M and clear cache sync; echo 3 > /proc/sys/vm/drop_caches But nothing happens(
My site wont automatically redirect from HTTP to HTTPS. Have gone through the forums and documentations but cant figure it out so posting. I am quite newbie to Magento. I am using Magento ver. 2.4.1. What I am trying to do is this:- www.mywebsite.com should automatically redirect to https://www.mywebsite.com My […]
Question: I’ve been using hyva-themes/module-magento2-admin to simplify admin area grid development in Magento 2, and it’s been fantastic. Now, I’m looking to leverage the same module to create a product grid on the storefront. While the module excels in the admin area, I’m unsure about its extension to the frontend. […]
When I run docker-compose up -d in my brand new cloned PWA Studio repo, this is what I got: WARN[0000] The "ENVFILEPATH" variable is not set. Defaulting to a blank string. Failed to load /projects/pwa-studio: read /projects/pwa-studio: is a directory How could I fix it?
I am learning “Set up multiple views in the Admin” I added a new website+store+view then opened store > system > configuration > general > web and tried to change store url. But checkbox doesn’t active. I select any store, view all the same. Now I cant’t change any setting […]
I have a problem with qtys when I’m trying to order the same product more than one qty. Example I have a T-Shirt with size: Small and qtys : 2 When I’m trying to order this products with 2 qtys in the backend the qtys reduced only one time. In […]
I am writing this since I have literally no idea in how to debug this anymore. I have a custom module that creates a csv feed and the uploads it to a digital ocean remote storage (space or whatever it’s name is). The problem is that the feed generates correctly […]
I am duplicating a product, disabling the old one and want to set the url of the new product to replace the old product. $duplicateParent = $this->productCopier->copy($oldproduct); $oldproduct->setUrlKey($existingUrlKey . '-old'); $oldproduct->setSku($existingSku . '-old'); $oldproduct->setVisibility(1); $duplicateParent->setUrlKey($existingUrlKey); $oldproduct->save(); $duplicateParent->save(); It’s throwing an error because the URL exists already, even though I’ve changed […]