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
3 answers
19 views

My website is not working, I am having this error

Warning: include(/home/occ_vikas/occasionsjo.com/var/view_preprocessed/pub/static/vendor/magento/module-theme/view/base/templates/root.phtml): failed to open stream: No such file or directory in /home/...
2 votes
4 answers
3k views

Magento 2: Collection getSelect does not load the results

I have this method public function getCarBrands() { return $this->_objectManager->create('Scandimedia\Wheels\Model\CarModels')->getCollection()->getSelect()->group('brand'); } ...
0 votes
1 answer
2k views

Can Not View Content Blocks due to require.js error - Magento 2 theme change

I am facing problem with require.js on Magento 2 theme change Content > Blocks The page shows endless spinner and I can never view my imported blocks for my new theme. When I do Firebug on the page. ...
0 votes
0 answers
13 views

Product Collection With Duplicates (On Purpose) For Admin Grid How?

I need to load a product collection that has repeated products in it. I get this error when trying to load a product collection with repeated products: Item (Magento\Catalog\Model\Product\Interceptor) ...
1 vote
2 answers
4k views

Magento 2 : Add category filter in producy grid

In admin, I want to add column of category and also add category filter in product grid. How to do this? Please help me. Thanks.
34 votes
10 answers
28k views

Magento 2 - How to add captcha to a custom form

I'm developing a custom module which contains a form submission. I would like to add a captcha to it. And we want to use the Magento default captcha library so that the captcha is consistent with the ...
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
3 answers
2k views

Magento 2 (Ubuntu) - Thumbnail image caching fails

I'm using Magento 2.1.0 with a bought with a template (SM Sawyer) on Ubuntu 16.04.1 Our products are being inserted/controlled by an external registration system. After this external source adds ...
5 votes
1 answer
2k views

Magento 2: Advanced Custom Fields for CMS Pages

As in Wordpress, we have https://www.advancedcustomfields.com/. So in Magento 2 we have http://www.advancedcontentmanager.com/download-acm-extension-m2.html It helps Customer/Client to Manage their ...
0 votes
0 answers
10 views

Custom Coupon Code Validation

Using Magento 2.4. I need some help in tackling a task. In a store developed with Magento2 I need to create/extend the validation for coupon codes. This particular store relies heavily on coupon codes ...
9 votes
2 answers
1k views

Overwrite js core function magento 2

I am trying to Overwrite some function from Magento_Swatches/js/SwatchRenderer.js file My code is for requirejs-config.js: var config = { config: { mixins: { '...
0 votes
2 answers
1k views

Magento2 - Get image url in model/helper

I have a helper class Email under vendor/module/model/helper/Email.php I have to access a image in the module_path/view/frontend/web/images I can't use $this->getViewFileUrl('vendor_module::...
0 votes
2 answers
1k views

Magento 2 moving top.search block before minicart

I seem to being having an issue with moving referenceblocks. I have created a child theme based off of Blank. In my default.xml file, I moved both minicart and top.search blocks into header.panel ...
3 votes
7 answers
10k views

Error "Payment model name is not provided in config" when having config in payment section

I have an extension that has some config fields in the payment section. The extension does not supply a payment method, I just want to have the settings in the Payment Methods section. module.xml: &...
1 vote
2 answers
735 views

two magento site in one elasticsearch

Is it possible to run one elastic search on two different Magento 2 sites? Currently, one Magento site running elastic search smoothly, but now I need to add elastic search in another Magento site ...
2 votes
3 answers
2k views

Magento 2 and Varnish 5

According to Magento DevDocs http://devdocs.magento.com/guides/v2.0/config-guide/varnish/config-varnish.html, Magento 2 supports Varnish versions 3.0.5 or later or any Varnish 4.x version. Is ...
1 vote
3 answers
1k views

Disable entries in system.log

I have Magento 2.2.x and system.log grows each minute, because of entries like: [2018-09-30 17:53:15] main.INFO: Add of item with id Magento_Customer::customer_manage was processed [] [] [2018-09-30 ...
1 vote
2 answers
22 views

Magento 2.4.4 API PUT products

question of interest. We are using the PUT command for updating our products, but the data in custom attributes are not cleared when not sending in the body: rest/store_view/V1/products/sku Is that ...
0 votes
2 answers
15 views

How to install 2 different magento2 instance with same server and same database

I want to install 2 magento2.4.4 on my server and connect with single database .
0 votes
1 answer
8 views

Magento 2 PWA Studio: Issue with SSL certificate

I'm using Adobe Commerce 2.4.4 with PWA Studio and I don't have a valid SSL validation in my browser during the local development. For the documentation, it should be working fine. How could I debug ...
1 vote
2 answers
4k views

Magento 2 Get Tax Amount is 0.000 in cart page ?

I get tax amount in cart page but it's 0.000.Why ? Can anyone help me ? print_r($this->checkoutSession->getQuote()->getShippingAddress()->getBaseTaxAmount());
0 votes
3 answers
4k views

Magento 2 How to restrict specfic ip address to access magento site in admin panel

I need to add specific IPs to access my magento website. How can I do that
0 votes
0 answers
8 views

How to check order Magento 2 order status delivered using UPS service?

How to I pull the delivered status from the UPS carrier tracking. Please advise me how to achieve in the Magento2 ?
6 votes
3 answers
5k views

Magento Subscription or Recurring payment

I am new to Magento and I want to know how can I sell "subscription products". Just like the one they have in Spotify. Users can avail of the premium account which can be renewed weekly, monthly, ...
0 votes
2 answers
33 views

Magento 2 - Add column to a table by using the declarative schema

I try to add two columns to the sales_order_grid table by following the declarative schema. Attempt: <?xml version="1.0"?> <schema xmlns:xsi="http://www.w3.org/2001/XMLSchema-...
3 votes
1 answer
969 views

Magento 2: performance of getCollection function

I'm currently working on a Magento 2 theme that requires collection statistics to show on the frontend. For example: what are the total number of customers at the moment. I'm using \Magento\Customer\...
1 vote
1 answer
2k views

What is the difference between getChildHtml and getChildBlock?

In the description of the method of getChildHtml it is said "Retrieve child block HTML" In the description of the getChildBlock method, it says "Retrieve child block by name". But what is the ...
0 votes
0 answers
13 views

Error in cURL request: Magento 2 error on admin panel

i need urgent help, i am getting curl request error when i go to Stores->configuration in magento admin panel. I am using magenot 2.4 Please can anyone advice what i can do to resolve this? https://...
11 votes
5 answers
17k views

Create magento 2 Patch

I am working on a Magento module that requires a quick fix. I assume I can fix it by creating Magento 2 "patch" way. I have never created a patch file before, can anyone help me to create a ...
3 votes
3 answers
2k views

Magento 2 : How to set the Title of Page in Admin Grid using UI_COMPONENT

I have created a custom module using UI_COMPONENT. Everything worked properly, but unable to set the Page Title. Index layout file: <?xml version="1.0"?> <page xmlns:xsi="http://www.w3.org/...
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
12 views

Magento 2 contribution automated tests

I've started to contribute on Magento Open Source project on Github. I did my first commit and opened a pull request. I added/replaced some lines of code in a JS file, trying to follow all the guide ...
0 votes
0 answers
10 views

"magento/module-new-relic-reporting" not installed after upgrade

So, I did a lot of research and tried a lot of ideas to solve this but without luck. That's why I'm asking. I'm trying to upgrade magento from 2.3.3 to 2.4.4 . I stacked on a problem that "...
1 vote
4 answers
1k views

Error: "Name Prefix" is a required value in Magento 2.2

I have made required 'Show Prefix' from admin config setting. Now prefix is shown on the customer account edit page. But, when i am trying to save customer prefix, then i am getting Error: "Name ...
27 votes
6 answers
57k views

How to disable the cache for the block in Magento 2?

protected function _construct() { $this->addData( [ 'cache_lifetime' => false, 'cache_tags' => array('MY_BLOCK'), ] ...
0 votes
0 answers
7 views

Is there any way to upload video from ui component in magento2

I am working on a custom requirement where a user can upload video from a custom UI component but I can't find any way for that. if there any way to do this in magento2?
3 votes
2 answers
1k views

Is there any tool to Convert magento 1 Product import csv file to magento 2

I have Magento 1 Product Import CSV file, I need to convert Magento 2 Product Import CSV Format. Is there any tool out there?. If not there means, Suggest me How to Convert it. Because ...
0 votes
0 answers
22 views

Magento2 How to optimize data of custom tab on product details page?

Magento2 I have too many tabs on product details page + some tabs has too many data. How can we optimize this? We used ajax to load data in this tabs but this is removing the success/error message.
3 votes
1 answer
37 views

How to get product collection without special price and tier price?

I'm using Magento v2.4, i want to retrieve a product collection that does not have special price (special price is not active or null) and tier price, currently i load the product collection like this:...
3 votes
2 answers
2k views

Function mcrypt_module_close() is deprecated in magento 2.3.1

Array ( [type] => 8192 [message] => Function mcrypt_module_close() is deprecated [file] => /vendor/magento/framework/Encryption/Adapter/Mcrypt.php [line] => 94 ) PHP ...
1 vote
1 answer
3k views

Show Product Review List Below Review form on product page in magento2

I want to show the Customer Reviews list below the review form Does anyone know a solution?
0 votes
2 answers
81 views

My Observer is not executing

Hi i'm new at magento 2 and i've been trying to create a Observer for checkout_submit_all_after and looks like that the Observer is not even called. events.xml <config xmlns:xsi="http://www.w3....
5 votes
3 answers
8k views

How to programmatically create an order in Magento 2 w/o using a cart/quote?

I've read a lot of answers to similar question, however all of them are suggesting to create cart/quote and then call placeOrder() or something similar. I need to create 'historical' orders. They ...
1 vote
2 answers
2k views

Magento 2.2 Programatically apply coupon code

How can i apply coupon code programatically in magento 2 using cart id. Thanks.
6 votes
2 answers
4k views

How to Integrate Magento Social in Magento 2.2

I would like to know more about Magento Social which was recently introduced in Magento 2.2. The module is available in the following location. System -> Extension -> Integration -> Magento ...
1 vote
1 answer
5k views

Magento2: Remove Category path from product URL is not working

I have a Magento2 store. I don't want to add the category path into products URLs for that I set “Use Categories Path for Product URLs” as "NO" in magento2 Admin, but It still add the category path to ...
2 votes
1 answer
2k views

Magento 2 Get Shipping Rates of All active shipping methods

I have a special case where I want to show all active shipping methods with applied estimated shipping cost to login customer if customer has default shipping address set in address book. The ...
0 votes
1 answer
2k views

Magento 2: Payment Method Not Capturing Shipping Address From Payment Page

On the Checkout Page after filling in the shipping address and checking the check box: my billing and shipping address are the same on the payment method it returns the error: Please check the ...
0 votes
2 answers
2k views

Magento 2 include google maps js only on contact page

I have a custom theme based on Luma, I'm trying to include google maps script only on contact page but it's not working. Here is my contact_index_index.xml file under my-theme/Magento_Contact/layout/...
7 votes
2 answers
4k views

Magento 2: Import/Export Product Attribute Set & it's Attributes

I refer Magento 2 - Export/Import Product Attributes but no one answered :( I have already created new Attribute Set & it's Attributes. I have checked Magento Default Import/Export for Products. ...

1
2 3 4 5
910