Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

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.

0
votes
0answers
3 views

Session generation error while trying to login in Amasty Checkout

I am getting this error "Warning: session_regenerate_id(): Session object destruction failed." while trying to login in Amasty Onestep Checkout. Can you please help me regarding this ?
0
votes
0answers
5 views

Google still crawls url while i disallow from robots

I will go straight to the point. Recently I did several fixes in my robots.txt file, and I've added several disallows like these: Disallow: /review/ Disallow: /catalog/product/view/ the problem is ...
10
votes
0answers
276 views

Magento 2 Show customer attribute in ui_component form

I've created ui_component form. Where I need to show customer details, Same as Customer Edit. But, I can able to show their data from customer_entity table. DataProvider.php public function ...
0
votes
2answers
25 views

Get website name from website id

I would like to add the magento website name to the top header beside the language switcher. Magento_Store/templates/switch/languages.phtml I can get the id by using, echo $block->...
0
votes
0answers
9 views

How to do customer login via mobile no and password RSET API

I have an issue while using end point of magento-2. I need to do the authentication using mobile no and password rather than email. I am explaining my code below. $adminUrl1='http://example.com/index....
12
votes
0answers
131 views

In Magento 2.2.4 Tier price of a simple product does not appear on a configurable product page

In Magento 2.2.4, Tier price of a simple product does not appear on a configurable product page after editing the cart. Steps to reproduce: 1)Select all option of configurable product which has a ...
0
votes
3answers
31 views

Magento 2: Adding a template file before the page footer (invalid template file error)

I am trying to add a template file above my footer to show a subscribe form. In my template I have created a file app/design/frontend/<vendor>/<theme>/Magento_Theme/layout/default.xml. ...
1
vote
2answers
137 views

Can't upload product placeholder images in Magento 2

v2.2.6 I'm trying to replace the Magento placeholder image with a custom one. Everything I browse to select the file and hit Save, nothing gets saved. Is there an issue with this in v2.2.6? What ...
0
votes
0answers
5 views

Magento 2 Scope Interface Model

I have recently gone through magento's core ScopeInterface file which is located in Magento\Store\Model. My question is why magento define SCOPE_STORES & SCOPE_STORE similar as WEBSITE and for ...
0
votes
0answers
10 views

How to fix the 404 You might want to check that URL again or head over to our homepage in magento2?

After migration product view page shows 404 You might want to check that URL again or head over to our homepage.H ow to fix the error? Please find the screenshot https://prnt.sc/lwvon9
1
vote
0answers
6 views

Magento 2 How to disable admin menu based on configuration?

xcz I want to hide my custom module menu based on configuration. If in configuration it set to "yes" then the menu should display and if set to "no" then menu should not appear at admin. I have ...
0
votes
0answers
5 views

How to save lines of my custom object via API?

I have the next JSON example and I need to save this with a model via POST. The problem is how to save the field lines of this JSON... { "sizeCurves": { "external_key": "...
0
votes
0answers
11 views

Login form validation is working but other forms validation is not working

I have tried all types of method but only login form validation is applying. But other forms not working. Even writing js in the phtml is not applying for the other forms. <form class="form form-...
0
votes
2answers
1k views

How to Magento 2 Enable JavaScript Bundling

I merged JS and CSS file Stores -> Configuration -> Advanced -> Developer -> Javascript Settings in production mode of magento2. Once, I check via view source of the page, I can see the Javascript is ...
0
votes
0answers
8 views

How to add the product Reviews and Rating in Magento 2 REST API

How to add Product Reviews and Rating in Magento 2 REST API ? As Magento 2 doesn't provide API for Product Reviews and Rating.
1
vote
1answer
29 views

Magento 2 move reviews form inside list.phtml file

By default magento 2 review structure is like this - /templates/review.phtml and inside it you have - /product/view/list.phtml and Magento_Review/templates/form.phtml files. form.phtml file is ...
0
votes
0answers
7 views

Magento 2 How can i override “email/items/price/row.phtml” in my custom module to send email with custom email template

I have created one module and i have observer there which called when order place. observer name sales_order_place_after. I want to send order email with custom email template. I tried to override \...
9
votes
4answers
5k views

How to create admin theme for Magento2

This method works for Magento 1 but not for Magento 2 (version 0.42.0-beta10): http://www.magentocommerce.com/wiki/4_-_themes_and_template_customization/admin/using_custom_admin_theme_templates
0
votes
0answers
9 views

Magento2: Aws CloudFront Product Image cache issue

I have integrated Aws CloudFront in our Magento 2 site. Product image not showing in our site. How to solve product cache issue. When I used CloudFront CDN URL. All images stored in the S3 bucket so ...
1
vote
2answers
65 views
+100

How to implement master/slave database configuration in Magento 2 community edition?

As we know master/slave or split database configuration is possible with Magento 2 enterprise edition and not with the community edition. How we can implement master/slave or split database ...
1
vote
1answer
38 views

load product grid ui component

I want to load the product grid via an ui_component. <fieldset name="fieldset_name"> <argument name="data" xsi:type="array"> <item name="config" xsi:type="array"> ...
1
vote
0answers
8 views

cataloginventory_stock_status randomly has missing entries

What could cause cataloginventory_stock_status to have missing entries I have to fix manually? It makes the product appear out of stock even though it isn't. I've tried replicating by flushing, ...
0
votes
1answer
12 views

in Magento 2 how to Open Modal popup with dynamic value for dynamic click button?

When I click on item "edit link" modal popup is open but when i edit other product it will show previous product data. Can anyone help to get dynamic popup with dynamic data in per different products?...
0
votes
0answers
21 views

I want to make changes to a extension That i purchased [on hold]

I have recently purchased an extension and would like to be able to customize it but I don't have any idea where to Start. Its IWD module. If anyone can help, please advise. Thank You!
0
votes
0answers
16 views

which event i should call after selecting shipping methods?

i want to write some custom code after selecting shipping method(Free shipping). I Tried with checkout_controller_onepage_save_shipping_method and sales_order_place_before but its not ...
0
votes
2answers
2k views

Magento2: Category id not showing at backend

I've installed Magento version 2.1.1 on my localhost. Then created few categories at backend. The issue is when I click on the category, it doesn't show ID of that category after the name of that ...
0
votes
0answers
7 views

Magento 2: Display widget on left sidebar product detail page for specific category whose product price is 0

Is there a way to add a custom widget that will handle on displaying CMS static block on the specific category which products is 0. It is like adding another option under Layout Updates when creating ...
0
votes
1answer
19 views

Magento2: How can solve cache issue when do redirection to login page?

I am facing issue of cache. I have added condition if customer not logged then user will redirect to login page every time. but it is working only one time and when I clear cache then again it work. ...
1
vote
2answers
24 views

How to modify the description of products in magento 2?

I have a simple plugin in magento 2 that modifies the name of the products, but I can not find the function that modifies the description public function afterGetName(\Magento\Catalog\Model\Product $...
1
vote
0answers
5 views

How can I sort a category product loop by position with elastic search outside of category page?

I am creating a product loop on the homepage of our site. The site has smile elastic search running. I have set up the manual sort for products in the category admin and can loop thru the products, ...
12
votes
4answers
12k views

500 Internal Server Error when installing magento2.2.2

I am trying to install Magento 2.2.2 on my local Windows environment with WAMP. But it gives me a 500 Internal Server Error. When I replace the previous version of htaccess file it does work. Would ...
0
votes
0answers
19 views

Catalog Search indexer process unknown error

I'm getting a 'One or more indexers are invalid. Make sure your Magento cron job is running.' and it seems I need to run php bin/magento indexer:reindex from the CLI. I get the index rebuilt ...
0
votes
0answers
77 views

Magento 2 : Syntax Error in Cron

I am trying to setup cron on magento 2, I am facing issues in that. cron log shows syntax error and 404 error.
0
votes
2answers
162 views

Move Search Bar - Magento 2.2.3

I am trying to move the search bar next to the logo on our website but not having any luck. My theme is based on magento luma. I have the below code <move element="block.search" destination="...
0
votes
2answers
872 views

Magento 2.1.1 - Display order subtotal in header

I have added the following to minicart.phtml for my theme and it doesn't work. $objectManager = \Magento\Framework\App\ObjectManager::getInstance(); $cart = $objectManager->get('\Magento\Checkout\...
1
vote
1answer
71 views

Adding External Link To Magento 2.1 Topbar / Navigation

I Have Followed Follwing Article From Stack Exchange For Adding External Link To Magento Navigation Also Referred Magento 2 Repo. And Created The Plugin. But Its Not Adding Link To My Navigation Bar.
2
votes
3answers
344 views

How can i redirect to homepage after login

I have used following code for redirect to homepage. But the page not redirecting after login. <?php namespace Vendor\Module\Controller\Account; use Magento\Customer\Model\Account\Redirect as ...
0
votes
1answer
2k views

Declaration of … must be compatible with

I have this module enabled, and when I try to run setup:di:compile I get this error Fatal error: Declaration of Mirasvit\Helpdesk\Ui\Component\DataProvider\FulltextFilter::apply() must be compatible ...
0
votes
0answers
6 views

Magento 2. Custom text in place of Price is not working Properly

In custom module I hide the Price and in the place of Price I tried to show Custom text it work perfectly but in some Categories it shows the custom text twice e.g men, Women. I can show the details ...
9
votes
5answers
16k views

Magento2 : How to get product id to my custom module

I am new to magento2 and currently I'm building a custom module and i want to get the product ID/SKU from the catalog. I'm trying to call using a function located in the Block folder. please advise!
0
votes
2answers
14 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)...
0
votes
0answers
7 views

how can i upload image with UI component in add new post form to database and show in phtml

i know this question is asked before but i can't understand properly from them.please some one provide latest solution for this how can i add picture of product to database from my UI (add new post) ...
0
votes
5answers
1k views

Magento 2 - Bestseller product collection

I try to get bestseller products on homepage with product collection in Magento 2. I only get Most Viewed product listing (?) and i cannot get bestseller products. My code it's: $objectManager = \...
0
votes
1answer
12 views

Magento2: How to get content of file from remote sftp?

I have one requirement in which i need to get zip file from remote sftp and read its data after extract it. I see there is class Magento\Framework\Filesystem\Io\Sftp which i can use like below. \...
0
votes
1answer
14 views

Magento 2 Child theme of Luma change media query

I have a custom theme that is a child of Luma. I see the styles-l min-width is set at 768px. Up until then the styles-m is active. I know if it was in my custom theme I could set that in my ...
0
votes
0answers
13 views

Magento 2 : Change image sizes in fotorama

How do I change the images sizes of the fotorama gallery ? From what I understand I need to edit my view.xml But what Image Id's do I need to change please. Also do I need to run some mage command ...
0
votes
1answer
8 views

Magento 2 : Multiple problems e.g. can't add categories or products

I installed Magento 2.3.0 via composer, now I turn on 2FA and then if I go to System--->All Users--->ME--->2FA there shows nothing? Also if I go to Catalog--->Categories--->Add ...
3
votes
1answer
1k views

How to reload the quote or cart in Magento 2

I am working on ajax cart. When i update the cart qty, I am trying to reload the quote but its not loading properly $this->cart->getQuote()->getShippingAddress()->collectShippingRates()-&...
0
votes
1answer
15 views

Magento 2 : Update url to domain

I'm using an Instance of Ubuntu 16.04 lts on Google to run a store, but I'd like to point to my domain. Wich line on Apache2 should I update?
0
votes
0answers
6 views

Wrong calculation of VAT on attributes

Hi, hopefully you can help me. I have a problem with the addition of a product price and a selected attribute (or more) price(s) In this shop I have entered the prices / TAX setting: 'excluding VAT'....