Skip to main content
New
Stack Overflow Jobs powered by Indeed: A job site that puts thousands of tech jobs at your fingertips (U.S. only). Search jobs

Questions tagged [magento2]

General questions about Magento 2, not specific to a minor version. Use this tag to distinguish from Magento 1. If you have issues with a specific version, please use the appropriate 'Magento-2.x' tag instead. Functionalities between Magento 2 minor versions might differ.

Filter by
Sorted by
Tagged with
0 votes
1 answer
1k views

Removing Cart items - Observer

I have added a custom product attribute with yes/no options. I need to delete products if 'no' attribute option is selected. I have successfully removed cart item using "...
1 vote
2 answers
79 views
+200

Widget not inserting or saving when the word 'type' is used anywhere in the text after a quotation mark

For a little context, we have recently made the decision to disable page builder and move towards a component-driven content entry approach utilising widgets. We have a "Generic Text" widget,...
0 votes
0 answers
5 views

Magento admin ui grid not loading

I am trying to create an admin grid module which loads custom data. I have created the small module to test the feature. However, the grid is not loading. Below is the code. Controller: app/code/Itm/...
0 votes
0 answers
5 views

Magento 2 Product Details page is being timed out

in our magento store everything was fine. But recently we are facing product details page is being timed out. CPU Usage is also getting high if we open that product details page. It is only happening ...
0 votes
1 answer
27 views

Magento 2 Map APIs Issue

I have deleted Array.from=$A from the legacy-build.min.js, google maps work Agien but other issue is dived, how can I solve this issue? can any one help please?
0 votes
1 answer
14 views

Magento 2 product search by keyword on the backend is returning a timeout

When I try to search for a product by keyword, it times out and shows a 524 error. When I checked the debug log, it showed a warning like the one below. Did not write session for ID ...
0 votes
1 answer
1k views

PDOException: SQLSTATE[HY000] [2002] No such file or directory error fixed, but now website is very slow / unresponsive

Before the fix, I tried to install the printful module, got through to Step 3 to where you enable the module and paused half way through execution. The front or back-end wasn't loading and after ages ...
0 votes
0 answers
24 views

image uploader does not work when more than one fieldset in admin UI Component Form in magneto 2

When we upload image with single fieldset it's working fine but when 2 fieldset is coming in picture then its' not working please check the error . Warning: Undefined array key "supplier-info][...
1 vote
1 answer
5k views

Magento 2 Reindex failed on customer grid

Magento 2 (Version 2.1.6) shows allways 2 or 3 Indexes with the processing state - and it never ends. It stays for days under processing. After a php bin/magento indexer:reset all the indexes are out ...
3 votes
2 answers
1k views

Magento 2 I Want to add Dropdown Quantity Box In Minicart

I am trying to replace Dropdown instead of text box at Quantity at Minicart. I tried following code but didn't get success ( i am trying direct in Magento Vendor folder for testing purpose). ...
0 votes
1 answer
15 views

The "oauth/consumer/enable_integration_as_bearer" path doesn't exist

I am trying to reset API but when I going to the path Stores > Configuration > Services > OAuth > Consumer Settings > Allow OAuth Access Tokens to be used as standalone Bearer tokens I ...
0 votes
2 answers
1k views

Magento 2 - Change category description, position and name programmatically

How can I change name desciption, position and image attributes for a category using code. I tried this code for changing the name, but without success: // $_this->cm is \Magento\Catalog\Model\...
2 votes
2 answers
3k views

Magento 2 Rest Api V1/products missing extension attributes

I am calling the Rest API V1/products to get the product list from Magento 2 store Request: http://{myMagentohost}/Magento/index.php/rest/V1/products?searchCriteria[currentPage]=1&...
1 vote
2 answers
5k views

Magento2: CRON Job is scheduled but Not Running

I have created a Cron job followed this question Installed the Extension and check it from admin back it says the job is pending. Below is the screenshot and my code in detail, Please let me know if ...
1 vote
2 answers
1k views

Magento2 Configurable product options not showing after data migration

After migration from Magento 1.9.3.6 to 2.3.5-p1 (also tested on 2.3.3, 2.3.4) the associated products for configured items are not available. First off, color is not added to attribute set "...
2 votes
1 answer
3k views

Errors while using data migration tool from 1.9.0.1 -> 2.1.2

I'm currently following through the Magento 2 Migration guide (http://devdocs.magento.com/guides/v2.0/migration/migration-migrate-data.html). I was able to successfully migrate settings, but while ...
0 votes
2 answers
1k views

PHP Deprecated: round(): Passing null to parameter #1 ($num) of type int|float is deprecated in

PHP Deprecated: round(): Passing null to parameter #1 ($num) of type int|float is deprecated in "PREPAID_TAXABLE_AMOUNT"=> (($item->getDiscountAmount()) ? abs( round($item->...
0 votes
1 answer
2k views

Magento 2 controller redirect on button click in phtml file

I want to redirect customer using controller when button is clicked in one of my phtml files. So far I got, controller: public function execute(){ return $this->addToCart(); } public ...
1 vote
3 answers
788 views

Magento 2 How To add Google Map in Ui Form

I'm facing following issue while adding google map with an api key, This site overrides Array.from() with an implementation that doesn't support iterables, which could cause Google Maps JavaScript ...
1 vote
1 answer
2k views

Fatal error: Allowed memory size of 2097152 bytes exhausted (tried to allocate 12288 bytes)

I'm getting the next error after docker-compose up. Fatal error: Allowed memory size of 2097152 bytes exhausted (tried to allocate 12288 bytes) in /var/www/html/vendor/zendframework/zend-...
0 votes
2 answers
2k views

redirect to the product url from observer or controller magento 2

i want to redirect from observer to the default magento product url from observer. public function __construct( \Magento\Framework\App\ResponseFactory $responseFactory ) { ...
0 votes
4 answers
3k views

How to show currency symbol and price in separate elements?

I want to show currency symbol and amount in separate html elements such as: BD18.00 into this: <span>BD</span><span>18.00</span> is it achievable?
1 vote
2 answers
2k views

Magento 2. Make soap response as array

I'm implementing custom API for Magento 2. My client want the response to be as associative array. Here is my class method: class Gcapiapi implements GcapiapiInterface { /** * Returns ...
0 votes
1 answer
2k views

Magento 2 - Duplicate Order Issue

I am currently running a magento 2 website (ver. 2.2.6). I have been an issue (pretty frequently) where some customers (not all) are reporting that they are commonly receiving an error upon ...
5 votes
2 answers
8k views

Transaction has been declined. Please try again later. - Error when invoicing

We're using Braintree to process payments (MCE 2.1.7) and are running into issues where on the braintree/paypal side of things, everything gets processed and goes through fine, and we've been able to ...
0 votes
1 answer
2k views

How to add javascript event to action button from product grid in backend

I am trying to open a new window on custom action link from product grid in admin panel. I created vendor/magento/module-catalog/view/adminhtml/ui_component/product_listing.xml into custom module ...
1 vote
2 answers
5k views

Notify for Quantity Below in Magento 2

I have a requirements to notify the admin through email when a product quantity goes below 5 in Magento 2.0.7. I have found that there is option on the admin: System > Configuration > Catalog > ...
0 votes
1 answer
1k views

How to remove or disable street address and city fields from shipping address in Magento2

Is there any solution disable or remove the city and street fields from checkout_index_index.xml? Thanks
0 votes
2 answers
1k views

How can i add select dropdown side of Mass action Button In Magento 2 Admin Side

I would like to get the select dropdown button on the side of Action Dropdown,for my custom grid collection at admin end, how can i achieve it,I would like to display the same dropdown beside. For ...
3 votes
2 answers
5k views

Magento 2 - Why is product image size & dimensions changed after upload?

When uploading new images to a product in Magento 2, it is not only decreasing the dimensions of the image, but it's increasing the image file size: Image Details Before Upload Dimensions: 1185 × ...
0 votes
1 answer
2k views

How to get checkbox value and save it on database

I have added a custom checkbox in checkout page, and I have added a custom column to sales_order and sales_order_grid tables, now I want to get the value of my checkbox and save it in my custom ...
15 votes
6 answers
2k views

Magento 2 How to add Tab Component in admin module

How can I add UI Tab Component in the custom admin module with the help of the below user guide? http://devdocs.magento.com/guides/v2.1/ui_comp_guide/components/ui-tab.html There are not enough ...
0 votes
1 answer
2k views

How can the billing address checkbox labeled "Save in address book" checked by default in Magento 2 admin create order page

We are trying to make the billing address checkbox labeled "Saved in address box" checked by default when the page loads. We are aware of the post: backend order create: default billing = shipping ...
0 votes
2 answers
2k views

Why Magento2 not loading css and js files in local setup?

my root folder .htaccess file RewriteOptions inherit # php -- BEGIN cPanel-generated handler, do not edit # Set the “ea-php71” package as the default “PHP” programming language. <IfModule ...
3 votes
3 answers
3k views

Success/ Error message not showing Magento 2

After Magento upgrades to its latest version, no success and error messages are seen to be added on the page message section while submitting the newsletter. But the email gets saved on to the backend ...
1 vote
2 answers
75 views

What new features or enhancements can we expect in the upcoming Magento versions in 2024?

As we anticipate the upcoming Magento versions in 2024, several exciting features and enhancements are expected to shape the platform's evolution. While specific details may depend on official ...
1 vote
1 answer
1k views

main.ERROR: The "EM0EM00284-100" product couldn't be removed

After upgrade to Magento 2.3.5, When trying to delete products from the catalog, we receive an error. This occurs on various types of products, from virtual products, simple products, configurable ...
4 votes
1 answer
5k views

Magento 2 check which catalog rule is applied to cart product

I have created 3 catalog rules for category. Shoes Category: 5% Off , Catalog Rule Name: Shoes Offer Toys Category: 10% Off, Catalog Rule Name: Toys Offer Fashion Accessories: 8% Off, Catalog ...
2 votes
1 answer
2k views

Magento 2 Component Manager Won't Load componentGrid/components Times Out

Magento is version 2.1.2 the issue is on the system > web setup wizard > component manager the page loads forever (ajax loading icon spins). My server is: Litespeed 5.0.9 PHP version 7.0.12 (all ...
0 votes
1 answer
1k views

Magento 2 product attributes hidden in product edit page?

I have a problem with magento 2. I created 2 attribute: show time countdown and show product on homepage. It work properly on localhost and other sites and magento versions. But I get an issue. All ...
0 votes
1 answer
5k views

Warning: ZipArchive::addFile(): Invalid or uninitialized Zip object

I am trying to zip the files in a folder. Example: In a path localhost/magento/var/log, there are two files system.log, debug.log. Following is the code which I tried to zip the files. Am developing ...
2 votes
1 answer
2k views

Magento 2 js library(Magento_Customer/js/customer-data) how to get custom product attributes in js

I've a little problem with an override of google tag manager in Magento 2 enterprise. google-analytics-universals.js have some function that trigger the events: addToCart, removeFromCart. To get the ...
0 votes
5 answers
1k views

Magento 2 How to disable module using xml file?

I am facing issue to create module. I created one module and I given apply to system admin to enable disable. So, Right now I am doing module hide/show using below code. $objectManager = \Magento\...
1 vote
1 answer
1k views

How to create custom text box attribute for configurable product in magento 2?

I want to create configurable product with dropdown and textbox field attributes. In frontend product detail page, dropdown can be shown but I also want to show textbox. Can anyone please guide me?
0 votes
2 answers
1k views

Invalid Return Type in Ajax Call

I made an ajax script to (at the moment) simply return some HTML to a select. My function looks like this: $.ajax({ showLoader: true, data: {val: inputVal}, /*dataType: 'json', (un)...
2 votes
1 answer
1k views

Magento 2 Get table name with prefix

I'm trying to get a table name with prefix. I currently try to use getConnection()->getTableName() but that doesn't work. I've seen people suggesting to use $this->_resource->getTableName() ...
2 votes
3 answers
2k views

Purpose of magento\generated\metadata\global.php file and is it safe to delete this file?

I encountered the following issue when I have moved Magento 2 module into production with the command setup:di: compile Uncaught Error: Call to a member function setActive() on boolean in /opt/...
4 votes
2 answers
2k views

How to create custom grid like sales order in magento2?

How to create custom grid like sales order gird with new,edit,save,delete,status,massdelete..etc in magento2.?
2 votes
1 answer
2k views

Magento 2. change customer custom attribute value from plugin

Here first question of mine. Now i added custom attribute to my customer following this code InstallData.php <?php namespace Kt\AddBonus\Setup; use Magento\Customer\Model\Customer; use ...
0 votes
0 answers
10 views

Magento 2 - Change value Quote item when I add to cart via Reorder button

I am trying to change a custom value each time I add to the cart via the “reorder” button. Right now I am trying to do this in the file “Magento\Sales\Model\Reorder\Reorder.php” but without success. ...

1
2 3 4 5
957