Questions tagged [magento2]
Magento 2 is an eCommerce project facilitating the improvement of Magento Core products. Written in PHP-Zend Framework. Available under both open-source and commercial licenses via Adobe Commerce.
magento2
5,090
questions
0
votes
0
answers
7
views
How to add Adalyser tracking tag in GTM for Magento 2
How we can integrate adalyser tracking code in GTM for magento 2.
and they are mentioning, These tags must be sequenced to fire after the all pages tag in order to function. any one can offer any ...
0
votes
0
answers
16
views
Docker Container for MariaDB, I am getting "bind: address already in use" error message [duplicate]
I am trying to setup a new Magento 2 local environment with Docker and the MariaDB container will not start and I get the following message.
"Error response from daemon: Ports are not available: ...
0
votes
2
answers
40
views
Magento 2: override .phtml file in a custome module
I am new to Magento 2 and I'm not quite understand its structure yet. I'm using its sample data to investigate code. I want to override a .phtml file by using a custome module. The file I want to ...
0
votes
1
answer
25
views
Setting Different Maximum Quantities for B2B and B2C Customers in Magento2
Is there a way to set different maximum quantity limits for B2B and B2C customers in Magento? For example, can B2C customers have a maximum limit of 20 items, while B2B customers have a limit of 100 ...
0
votes
1
answer
39
views
after upgrade scripts on checkout not loading
After I upgrade to magento 2.4.7-p1, on checkout page scripts are not loading.
On any other page the url from requirejs is
https://app.exampleproject.test/static/frontend/Mgs/claue_child/pl_PL/jquery....
0
votes
0
answers
13
views
Issue with tests generating (magento. mftf)
mftf is new experience for me and sry if this question is to lamer
When i execute the following command
vendor/bin/mftf generate:tests
the following result is appears:
Warning: DOMXPath::query(): ...
0
votes
1
answer
68
views
Magento 2.4.5-p8 with CSP on scripts inserted by Google Tag Manager
We're updating our Magento from 2.4.5-p7 to 2.4.5-p8.
As you know, in Magento 2.4.5-p8 the CSP on the checkout page is now restrict mode instead of report-only.
We know now that the scripts inserted ...
0
votes
2
answers
36
views
Magento 2 after upgrade
I have upgraded magento from 2.4.3-p2 to 2.4.7-p1.
I did it on local machine using docker/warden instance.
I use opensearch and admin shows that I`m connected.
I did
s:up,c:c,c:f, static:content:...
0
votes
0
answers
7
views
Magento 2 - layered navigation filter missing (when attribute value is not set on at least 1 product)?
I have noticed that if attribute value is not set on at least 1 product then filter for that attribute wont be shown in magento 2 layered navigation?
If I have 1000 products and there is 1 where I ...
0
votes
0
answers
13
views
Magento 2.4.6 select query consuming all resource cron jobs
We have a select statement that we cannot trace and keeps being run multiple times
`SELECT `e`.*, IF(at_status.value_id > 0, at_status.value, at_status_default.value) AS `status`, `at_visibility`.`...
0
votes
0
answers
36
views
Disable customer shipping adresses if it not belong from US magento2
I want to Disable shipping adresses if it's not matched with usa country or shipping origin country on checkout page magento2
I want to know how we can overwrite knockout file related to this task in ...
0
votes
1
answer
27
views
How to display item count in menu of magento2 admin?
in the magento2 admin side, I want to display the records count if I have 5 records in operations the 5 will be displayed in order in the menu, I have multiple items in the menu. Each record will show ...
-1
votes
0
answers
28
views
Add id href to url to Magento 2 php attribute
in Magento 2 I am getting a product link from an attribute like so
<?= $_product->getData('ecc_related_documents_synced') ? '<a href='.$_product->getData('ecc_related_documents_synced').' &...
0
votes
1
answer
38
views
Magento deprecated \Magento\Framework\App\Action\Action
Magento 2.4 deprecates class \Magento\Framework\App\Action\Action
and suggests using \Magento\Framework\App\ActionInterface.
But what about dispatch() method?
I need to do some checks in controller (e....
0
votes
0
answers
20
views
venia-ui- Magento PWA
I was asked to update venia/ui in my project.
I saw that there are lots of error in the move from version 7 to newest version so I decided to update for version 9.2.0 which is a version I have in ...
0
votes
0
answers
10
views
Overiding Only a Few Specific Canonical Links with Default Value = Yes - Magento 2
In Magento 2, we have Stores -> Catalog -> SEO -> "Use Canonical Link Meta Tag For Categories" and "Use Canonical Link Meta Tag For Products" set to "Yes". This ...
0
votes
0
answers
27
views
Magento 2 | Smile Elasticsuite search results get all - "*"
In Magento 2 when I search for "*" in search field, all products are shown. I noticed that this is because of Smile Elasticsuite extension. Without that it wont work.
Does anyone knows how ...
3
votes
1
answer
36
views
Magento 2 cloudflare unable to install Matomo
We are using magento 2 with Cloudflare enabled on the website but when we try to install Matomo getting this issue on the browser console -
index.php:1 Refused to load the script 'https://static....
0
votes
0
answers
16
views
Braintree with Paypal not working with Multi Website and Multi Currency setup - Sandbox Environment
I am experiencing an issue with PayPal used with Braintree Sandbox. I have multi website setup. US and UK website. UK website is working fine and accepting the payment in GBP using PayPal.
I am using ...
0
votes
0
answers
37
views
Magento 2, RequireJS: r.js cannot parse ES6 syntax
I am maintaining Magento 2 store. Since we have issues with RequireJS preformance, I decided to try optimizing following this tutorial Advanced JS bundling.
I have problem on "Run the r.js ...
0
votes
0
answers
21
views
Magento DB Downgrade 2.4.3 EE to 2.4.6 CE
I am downgrading Magento 2.4.3 Enterprise edition to 2.4.6 community edition. While downgrading I am following few already available modules and blogs like below
https://github.com/opengento/magento2-...
0
votes
0
answers
16
views
Magento2 cusotm module and uiComponent won't load items, infinite spinner and "We couldn't find any records"
I have created a custom module that's purpose is to manage Vendors. I have created a Collection, CollectionFactory, DataProvider, di.xml, vendors_vendor_listing.xml and so on and so forth.
I am able ...
0
votes
0
answers
31
views
Magento 2 all admin ajax requests are returning html instead of json
I have migrated the Magento 2 code to a different server and setup the same codebase on my local/wamp server.
The admin pages are not showing any data but on my local/wamp server all admin pages like ...
-1
votes
0
answers
25
views
How to solve problem in magento 2 with empty cart in FireFox?
In Firefox, when adding a product to the cart, an Ajax request is made to /customer/section/load/ and an empty cart is received in response, although the product ends up in the cart. With a normal GET ...
1
vote
0
answers
26
views
Magento Custom Variable for current Category name?
I'm trying to create a custom variable in Magento2 that I could use within a CMS block on a category page, that would result in displaying the name of that category.
For example, within a block at the ...
-4
votes
0
answers
25
views
Rewrite this model function sendEmail
I have a problem with the Magento2 newsletter module, I need to edit the sendEmail function, there is the email variable in this function that takes the template, I need to change it according to ...
0
votes
0
answers
51
views
Magento 2 UI Listing: show/hide grid columns based on condition
I am writing listing UI Component (local_comments_grid_listing.xml).
It has <dataSource> with <dataProvider class="Local\Comments\Ui\Component\DataProvider\ListingDataProvider">.
...
0
votes
0
answers
38
views
Magento 2 API: 401 Unauthorized for Salesrule calls with Admin Bearer Token
I am using the Magento 2 API to convert quotes (from custom made laravel project) to orders. I use an administrator bearer token, which works successfully for other API calls such as:
Create guest ...
0
votes
0
answers
37
views
Why can't I use Xdebug in PhpStorm? I'm using PHP 8.1 and Xdebug 3.3
When I run Xdebug for my index page it gives me an error:
/bin/php -dxdebug.mode=debug -dxdebug.client_port=9003 -dxdebug.client_host=127.0.0.1 /var/www/html/thang/app/code/Smartosc/Thang/Controller/...
0
votes
1
answer
31
views
YOTPO how i can reach elements via js
I have yotpo on my website and need to add GTM events so i connected custom js to my yotpo page and trying to do something when i click on button that comes from yotpo. I tried call it by css class. ...
0
votes
0
answers
34
views
Magento Partial Layered Navigation
So my boss asked me to help with his website. He wanted to be able to filter products via attributes. I made some progress but i come across issues like this:
full web screenshot
where the attribute ...
0
votes
0
answers
19
views
Magento 2.4 product details page my custom form submit then get errror
i am created custom module as per requirement.my details page add custom button when click then open popup and submit data. at time my data is save database and admin grid but email not send. i will ...
0
votes
0
answers
27
views
Caching Pages While Ignoring Specific URL Parameters
I am new to Magento and developing a website where certain URL parameters are unique, but do not affect the page content. For example:
User 1 visits: example.com/product/view?id=123&example=xyz123
...
0
votes
0
answers
29
views
magento oauth request_token returns Net::HTTPRetriableError: 302 "Found"
I am using oauth 1 to connect allow users to authorize their Magento store. I keep getting Net::HTTPRetriableError: 302 "Found" when requesting a token.
To confirm, site is our magento admin ...
0
votes
0
answers
20
views
Magento 2 - Filterable product attribute in layered navigation visibility?
Is filterable product attribute visible in layered navigation in magento ONLY when all products have value set for that attribute?
I have filterable select attribute which is not required and it is ...
0
votes
1
answer
36
views
I want to add a custom graph to a specific position on the admin dashboard in Magento 2.4, but it isn't working. How can I fix this?
I want to add a custom graph to a specific position on the admin dashboard in Magento 2.4?
I have tried this but this does not work.
<?xml version="1.0"?>
<page xmlns:xsi="http:...
0
votes
0
answers
15
views
Magento 2 - Custom product select attribute is not shown in layered navigation
I have created custom product attribute input type select with configuration below in code sample that is provided.
After creating attribute I assigned added options to that attribute in magento admin ...
0
votes
0
answers
69
views
magento cloud version upgrade to 2.4.7 completed but getting failed to load component error on checkout page for all custom modules
magento cloud version upgrade to 2.4.7 completed but getting failed to load component error on checkout page for all custom modules.
there are lots of error related to system upgrade / compatibility ...
0
votes
1
answer
31
views
"InvalidCheckoutSessionStatus" Error while firing CompleteCheckoutSession GraphQL End-Point
I am working with Amazon Pay and Adobe Commerce integration. I have Amazon Version 5.14.1. I have integrated this in Headless architecture using GraphQL.
I am able to redirect to Amazon page to enter ...
0
votes
1
answer
20
views
Changing the default Magento category ID: 2
I am working on a Magento 2 project and need to change the default root category ID, which is currently set to 2, to a different value. I have explored the Magento Admin Panel and database but have ...
0
votes
0
answers
23
views
How to remove unused js and css from magento scandi pwa website
In website usually chunk css and js files will be generating while building. how to remove those unused css and js files from our sites to improve site performance.
is there any ways to avoid them and ...
0
votes
1
answer
46
views
Configure Docker, Traefik and Bitnami Magento2 for SSL / letsencrypt / certbot
I am trying to configure bitnami's docker implementation of Magento from GitHub to run with Traefik.
I have these two files:
docker-compose.yml
# Copyright Broadcom, Inc. All Rights Reserved.
# SPDX-...
0
votes
1
answer
132
views
Magento 2 get categories path names from product
I am trying to get for each product the category paths with names and exclude the root category(id 1). I separate them with
%%
I use this code:
<?php
$categories = $product->getCategoryIds();
$...
0
votes
1
answer
28
views
How to upload product image label for all store in magento 2 when import product using csv
How to upload product image label for all store in magento 2 when import product using csv
Now we need to add multiple row for same product when want to update images label so can we update using ...
0
votes
2
answers
35
views
Migrated from Magento 1.9.2 to 2.4.6-p5, after migration all category urls showing 404
Migrated from Magento 1.9.2 to 2.4.6-p5, after migration all category urls showing 404.
Any Idea how to solve this issue?
I have tried options like re-indexing, cache clear, setup:upgrade, di-compile, ...
0
votes
1
answer
34
views
Influence of _cl tables on product import & incremental indexing
I use SQL Import functionality outside Magento 2 Bootstrap. It perfectly works, but I have a degradation. After 2M imported products daily import benchmark decreased in 3 times. After figuring out I ...
0
votes
0
answers
43
views
Unable to save the product due to mismatched tier price in Magento 2
Initially, we replicated the tier price with a specific store. Later, we changed it to apply to all websites. As a result, all tier pricing information is now mismatched. I can observe that the same ...
0
votes
0
answers
16
views
Could someone assist with resolving an issue related to the checkout agreement?
The checkout agreement is enable for multi site but its giving the error Error: Call to a member function isSetFlag() on null in /var/www/projects/cei-shop/vendor/magento/module-checkout-agreements/...
1
vote
0
answers
42
views
Sorting the collection of catalog products by attribute and its specific parameter Magento 2.4.6
I have a custom attribute named "Promotion" (ID: 489, code: "special_attributes") which includes four options: Promo, Sale, etc. I need to sort the catalog product collection by ...
0
votes
0
answers
37
views
Socket Hang Up issue in Vue Storefront with Magento backend
We have encountered the following error on our website, https://mpex-2gqq4.ondigitalocean.app, which is a Vue.js (Vue storefront) website using Magento as the backend. The website calls APIs using ...