I try to make some pages with 404 status and ouptut 404 page but with current url. I do it in observer. This is my events.xml <event name="catalog_category_load_after"> <observer name="empty_to_404" instance="ProviderModuleObserverCatalogEmptyTo404" shared="false"/> </event> This is a class of Observer /** @var ResponseFactory */ protected $responseFactory; /** @var UrlInterface */ protected […]
Magento
The story so far: I’m updating Magento from 2.3 to 2.4 and in doing so I’m now getting an “Area code is not set” when running any CLI command. This did not happen in 2.3 and after looking at the following stack trace from bin/magento s:di:c –verbose I have the […]
I am taking Magento courses in Adobe commerce, but finding it difficult to follow the code structure. I am basically a OOPS and SQL developer so not that familiar with latest front end technologies. Can someone help which basic courses I should take before continuing with Adobe training. I am […]
I have HTML file which is hosted on other server. http://testsite.com/test/index.html which has the content like this(As a example) <!DOCTYPE HTML> <html> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8"/> <link rel="stylesheet" href="css/custom.css" type="text/css"> <script src="js/custom.js"></script> </head> <body> <div class="container"> <div class="homepage"> <div id="testdiv" class="test-container"> <div id="text"> <div class="center"><h2>Welcome page</h2> <h3>Custom text goes […]
I want to use 2 observer on ‘sales_order_place_after’ this observer as i have checked if i place one observer it works fine but how can i run 2 observer with one event. <event name="sales_order_place_after"> <observer name="sales_order_place_after" instance="HlSendEmailObserverCustomerNewOrderObserver"/> <observer name="hl_sales_order_place_after" instance="HlSendEmailObserverAfterOrderObserver" /> </event> here oage got stuck on checkout and nothing […]
In Magento 1 need to make a SOAP call for a certain category in order to extract information. For that I use below request: $result_ = $client->call($session, 'catalog_category.info', 90); However, since the store is in multiple languages I need to send along a store_id to be able to collect the […]
Basically I am getting error We can’t find the quote item after update cart for configurable product. There are no issues in adding item to cart. Also I am not getting any error’s or warnings while adding or updating item to cart through which I can debug and trace the […]
I have added a DataRange filter like this on a listing ui component: <column name="fecha_order" sortOrder="20"> <settings> <filter>dateRange</filter> <label translate="true">Fecha</label> </settings> </column> Then I get the values here in a custom Data Provider public function addFilter(MagentoFrameworkApiFilter $filter) { $writer = new LaminasLogWriterStream(BP . '/var/log/filters.log'); $logger = new LaminasLogLogger(); $logger->addWriter($writer); $this->_session->start(); […]