All Questions

Filter by
Sorted by
Tagged with
52
votes
3answers
8k views

Run tests for a specific module in Magento2

Running the tests for Magento to using php bin/magento dev:tests:run takes a lot of time. Is there a way to run the tests for a specific module only? I'm a noob in (unit) testing so have mercy.
52
votes
2answers
27k views

Magento 2 - How to add a custom field to checkout and then send it

All tutorials are covering only adding a fields, but saving value of this fileds is skipped #mindblown. I don't know why, it's most important part of adding any field or form. I tried to follow ...
50
votes
8answers
42k views

How to Override Core Block, Model and controller in Magento2

I'm stuck in overriding core model Blocks and Controllers in Magento 2. Can any one help on this? Let's take list toolbar as example where I need to add a new sort option called sort by most popular. ...
50
votes
6answers
31k views

Critical Reminder: Download and install Magento security patches. (FTP with no SSH access)

The Magento security patches look like they are .sh files, how would someone apply these patches without SSH access to their Magento installations? Also, are these patches cumulative? IE: Will they ...
49
votes
10answers
79k views

How to reset lost admin password in Magento 2?

I tried to reset the admin password via Phpmyadmin in admin_user table but this doesn't seems to work. Also on chrome I am getting "This webpage has a redirect loop" error when loading admin page.
49
votes
4answers
37k views

Difference between website, stores and store views

I have been researching about multi website/store setups and am a little confused. I completely understand how stores and store views work but my confusion is on the differnece between websites and ...
49
votes
5answers
54k views

Search Type: Like, Full Text or Combined?

What is the difference between the different search types? Like Full Text Combined I am specially interested in how the search behavior and performance changes for those settings.
49
votes
4answers
14k views

Passwords in sign up email. Bad practice? PCI compliant?

We use Magento Enterprise (1.12) and I have had several customers email me already complaining that they received their password via email when they signed up for an account. I know this is considered ...
48
votes
14answers
123k views

How do I set Developer Mode in Magento 2

I'm trying to install Magento 2 but I am getting the following error: Error happened during application run. Could not write error message to log. Please use developer mode to see the message. I ...
47
votes
3answers
15k views

Magento2: what is the basic difference between plugin and preference?

I used both Plugin and Preference in Magento2 tutorial and both are working fine but what is the basic difference between them. Code for plugin: 1.1) Add a plugin declaration into di.xml: <type ...
47
votes
2answers
5k views

Magento Event Observers: Singleton versus Model

So Magento offers 2 ways of declaring an observer. Singleton and Model (new instance) by specifying the <type> tag in Magento 1.x and by specifying the shared attribute in Magento 2. Magento 1 ...
47
votes
7answers
18k views

Price re-index causes DB deadlocks during checkout

I'm experiencing an issue where I believe the Product Price re-indexing process is causing a deadlock exception in the checkout process. I caught this exception in the checkout process: Order ...
46
votes
17answers
75k views

Magento 2: Safe and easiest way to disable Compare products & Wishlist Module

I am building Magento 2.0 only to sell 2 of my products online. The compare products and wishlist module is irrelevant for me. How I safely and easily remove those modules? I dont want to hack the ...
46
votes
17answers
13k views

Security Patch SUPEE-10570 - Possible issues?

Magento has released a new security patch for M1, and updates for M1 and M2. What issues should I look out for when upgrading or applying this patch? SUPEE-10570 SUPEE-10570, Magento Commerce 1....
45
votes
6answers
38k views

How to add fee to order totals in Magento 2

The following link will describe http://excellencemagentoblog.com/blog/2012/01/27/magento-add-fee-discount-order-total/ to add fee to order totals in Magento 1. Now this functionality is moved to ...
45
votes
4answers
69k views

Magento2 how to getRequest

In Magento 2 how to receive request array? $_POST and $_GET too as we did in Magento 1: Mage::app()->getRequest()->getPost()
45
votes
5answers
118k views

How to get all items in cart currently?

I want to get a collection of all the items in cart currently. How can I do this ? Any suggestions will be appreciated.
45
votes
12answers
45k views

How should I handle session files that become too numerous?

I am acting as a sysadmin for a couple of servers that hold Magento sites and occasionally they fill up with session files. I have been told that managing these files isn't something that can be done ...
45
votes
3answers
14k views

APPSEC-1057 How to add variables or blocks to the white list tables

APPSEC-1057 (part of SUPEE-6788) states Magento now includes a whitelist of allowed blocks or directives. If a module or anyone uses variables like {{config path=”web/unsecure/base_url”}} and {{...
45
votes
2answers
22k views

What's the preferred way of throwing exceptions in Magento?

All of the following methods are used in Magento core so which one is the preferred (or the latest "best practice") way? Mage::throwException('Some Message') - 732 Usages throw new Exception('Some ...
45
votes
1answer
2k views

Magento 2 Adminhtml spreading forms across multiple tabs

I'm attempting to create a backend module, where in my edit page I use admin-2column-left layout. I want to have a form on each tab, but I don't know how I can do this. Ideally, I would like to know ...
44
votes
8answers
67k views

How To add JS file in frontend for all pages

I've read 3 pages of Google Results on how to load a JS file for all pages and still am not able to do it. I've got a few doubts, hope somebody can clear them out. Do I need to create a module ...
44
votes
4answers
50k views

How to check the latest patch version applied to magento?

I just applied the security patch PATCH_SUPEE-5344_CE_1.8.0.0_v1-2015-02-10-08-10-38.sh Since I have no SSH access to the web server, the provider did the work for me. How can I check by myself if ...
44
votes
2answers
26k views

When should I use the Magento Compiler

I often see people mention they use the compiler feature of Magento. I do never and wonder, which cases you should use it and how much performance gain you have then. [DISCLAIMER]: As I got an edit ...
43
votes
7answers
69k views

How to update Magento2 using composer

I can't seem to be able to update my magento2 ce using composer. I doesn't find any updates, the only one it found was 'fabpot'. I thought this was the whole point of a composer setup, so why would I ...
43
votes
3answers
76k views

Remove block from layout XML in Magento 2

In Magento 1 I could remove a block added by a layout file by adding this in my layout-block <remove ="block_id_here" /> How can I do the same for Magento 2? As a practical exercise, let's say ...
43
votes
9answers
46k views

Magento 1.9, php 5.6 - Use of iconv.internal_encoding is deprecated

Have the same with Magento CE 1.8 and 1.9 After update php from 5.5.16 to 5.6.0 on my VPS I got this 2 errors in [magento]/var/log/system.log: ERR (3): Deprecated functionality: iconv_set_encoding():...
43
votes
12answers
61k views

Customer Login Doesn't Work in 1.9

I just did a fresh installation of Magento 1.9.0.1 and I am seeing some very odd behavior with the customer login form. In Chrome (version 36) the login form does not work. I am just redirected to ...
43
votes
6answers
71k views

Magento upgrade from 1.7 to 1.9

I need to upgrade my Magento store from 1.7 to 1.9. I am very new to Magento, SSH and MySQL. I was just wondering what is the easiest way to upgrade without breaking my website.
43
votes
1answer
7k views

Difference between /Controller and /controllers

A question I've been meaning to ask for ages, more theoretical than anything else. I'm fully versed in developing Extensions using the normal Magento module file structure. I've noticed though when ...
42
votes
5answers
2k views

What do I do when an extension overwrites a class globally and I want to use the original?

We're using an extension which globally overwrites the Mage_Catalog_Block_Product_List_Toolbar block. <global> <blocks> <catalog> <rewrite> ...
42
votes
1answer
7k views

How to add a new product type in Magento 2? (MageStackDay mystery question 1)

MageStackDay bonus question for 500pts Bounty AND a the possibility of winning a free Z-Ray license for a year. More info can be found >> here << The questions are provided by Magento 2 core ...
41
votes
17answers
64k views

Magento 2.2: Unable to unserialize value?

Running into issues on a site running Magento 2.2.0-rc3.0/PHP 7.0.23 The following issue occurs with all 3rd party extensions either enabled or disabled. When adding an item to comparison from ...
41
votes
14answers
53k views

Magento 2: How to truncate customers, products, reviews and orders table

Does anyone have list of tables I need to truncate to delete all test customers, products, reviews and orders in Magento 2 ? I'm looking for something similar to Clearing Magento after testing .
41
votes
7answers
4k views

What are good ways of monitoring a live shop?

Preface: We want to extend the monitoring of one of our webshops as the provider had troubles with the PHP configuration and parts of the live webshop crashed (backend & checkout not working). I ...
41
votes
8answers
1k views

How to evaluate 3rd party extensions?

While Magento does a lot 'out of the box', we've found there are inevitably features and facilities needed for client stores that require a 3rd party extension. However, given the nature of the ...
40
votes
3answers
64k views

How to Set, Retrieve and Unset Session Variables in Magento 2?

What is the equivalent for session in Magento 1 Mage::getSingleton('core/session')->setMyValue('test'); Mage::getSingleton('core/session')->unsMyValue(); Same in Magento 2?
40
votes
2answers
134k views

How do I fix my Base URLs so I can access my Magento site?

I changed Base Urls and now my website is inaccessible I moved everything to a new server, didn't change the base_url and my website is inaccessible How do I change or restore base_url my BaseURL ...
40
votes
5answers
7k views

Magento coding standards

I recently started working extensively with Magento and Code sniffer, and I would like to know which standards I should follow. I tried Zend coding standards, but I don't want to use the 80 line ...
39
votes
11answers
63k views

How to Remove Customer Account Dashboard Links

I want to remove following links in the customer account dashboard left panel? My Applications Gift Registry Reward Points Gift Card Link I'm working in the Magento 1.7 Community Edition. Any ...
39
votes
1answer
15k views

Product.OptionsPrice is not a constructor magento 1.9.3

I have upgrade magento 1.9.2.4 to 1.9.3. I am facing the following error in the console in product page. TypeError: Product.OptionsPrice is not a constructor var optionsPrice = new Product....
39
votes
8answers
79k views

Magento 2 404 error for scripts and css

I have downloaded and installed Magento 2 from https://github.com/magento/magento2 But I am getting 404 error for scripts and cs located in http://localhost/magento2/pub/static/ I have checked, ...
39
votes
6answers
70k views

Add a static image on PHTML page and CMS Blocks : Magento2

How I can Add a static image on PHTML page and CMS Blocks into Magento2? in Magento 1.x it was possible using $this->getSkinUrl('images/xyz.jpg') I am trying following method into Magento2 In Phtml ...
39
votes
8answers
5k views

What is Progressive Web Apps, or PWAs in Magento 2?

What does it mean that Magento is becoming a Progressive Web Application platform? What will be the code structure of PWAs in Magento? What is the deal with REST APIs and PWAs?
39
votes
1answer
29k views

How do you override LESS in a custom theme?

I've spent the better part of this week trying to find a clear guide on how to properly create a custom theme and extend exist LESS/CSS without having to copy the entire magento-blank theme. The ...
39
votes
3answers
7k views

What Triggers the Generation of a Factory in Magento 2

Magento 2 contains a number of class files that are either pre-generated, or are generated on the fly. They live in var/generated These generated files include factory classes. From the ...
39
votes
1answer
2k views

Why is there no partial re-indexing for EAV and tags?

This question was puzzling me for quite a while. Why is the improvement bugfix introduced in Magento 1.13.x.x called partial re-indexing not covering "Product Attributes" and "Tags Aggregation Data" ...
38
votes
22answers
173k views

Magento 2 CSS and JavaScript not loading from correct folder

I am attempting to install and run Magento 2 on WAMP on a Windows 7 machine with little success. After jumping through the many and various hoops to get the site to load I am now faced with 404 ...
38
votes
3answers
68k views

Extending / Overriding JS in Magento 2

As Magento2 is using RequireJS for loading scripts, and there's no more skin folder, I've stuck with a problem: How can I replace Magento's module JS file by my modified version? For example — the ...
38
votes
5answers
86k views

How to fix Magento 2 2.0.0-RC Admin page not found after installation

It's a fresh new install with a clean database. I checked the values from Magento 2 : Error 404 not found at magento 2 admin login page and it's fine too. Also tried to access it via /index.php/admin ...

15 30 50 per page