Skip to main content

All Questions

Filter by
Sorted by
Tagged with
91 votes
30 answers
138k views

Required parameter 'theme_dir' was not passed

What is the error message: Required parameter 'theme_dir' was not passed Is it related to in Magento 2? And how can this problem be fixed?
hakre's user avatar
  • 2,841
81 votes
4 answers
30k views

Fundamentals for debugging a Magento store

How can I debug my Magento store This is a question that isn't all too relevant to us now, but had a Magento SE site existed 5 years ago, it probably would have been our first question. For those ...
Ben Lessani's user avatar
  • 17.7k
40 votes
1 answer
35k 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 ...
andyjv's user avatar
  • 3,252
38 votes
2 answers
11k views

Magento 2 - Theme Type 0:physical, 1:virtual, 2:staging. When to use?

In the theme table there is a type field with 3 possible values: physical, virtual and staging. When to use physical virtual and staging theme? When I extended luma theme my new theme appear in ...
PD81's user avatar
  • 563
36 votes
7 answers
37k views

Move all Javascript includes to before </body>

Does anyone know how to have all of Magento's JS script tags e.g. <script type="text/javascript" src="http://sitename.com/js/prototype/prototype.js"></script> render out before the closing ...
Mark Weston's user avatar
32 votes
2 answers
94k views

How to use jquery library in Magento 2?

I am creating a Magento theme where I need to include jQuery. When I add this <link src="js/jquery-1.7.1.js"/> in head. It is working but Magento javascript functions are not working. How to ...
Qaisar Satti's user avatar
  • 32.5k
30 votes
5 answers
25k views

Get product attribute in cart in Magento2

I'm trying to grab a product attribute in the cart template. But I just does not work! The attribute is set to Visible on Catalog Pages on Storefront = yes and Used in Product Listing = yes I use a ...
tecjam's user avatar
  • 4,033
30 votes
4 answers
20k views

Theming for Magento 2 - Starting from scratch

Some of you probably read that topic regarding theming from scratch for Magento 1: Theming - starting from scratch I was wondering, what would be the best practice to develop a theme from scratch for ...
Raphael at Digital Pianism's user avatar
30 votes
2 answers
7k views

Theming - starting from scratch

What is the preferred method of beginning a full site build, from scratch? My builds typically begin from fully mocked-up HTML5 wireframe pages, and we plug in functionality from there. But, part of ...
philwinkle's user avatar
  • 35.8k
29 votes
3 answers
32k views

How to implement translations in design template package CSV's? How does echo $this->__('Text') work?

I have a design package setup like so: design/frontend/package_name/theme_name/locale/ under which I have de_DE, en_GB etc, under which I have corresponding translate.csv files with the various ...
waffl's user avatar
  • 723
27 votes
4 answers
13k views

Why do classes use a helper for translation instead of $this?

In core modules and sometimes templates, I see helper classes being used for translation: Mage::helper('someModule')->__('translate me'); Why is this preferable to: $this->__('translate me');
Brendan Falkowski's user avatar
26 votes
4 answers
27k views

Magento 2: requirejs-config.js in themes?

Is it possible to include a requirejs-config.js file (or otherwise configure RequireJS) via a Magento theme? Or is the capability reserved for Magento modules? The dev docs information on theme ...
Alana Storm's user avatar
  • 44.4k
26 votes
3 answers
5k views

When to use 'name' and when to use 'as'

I've found that when trying to use the unsetChild method, sometimes I have to use the 'name' attribute and others 'as'. It seems that if a block is added normally, you use 'as' but if it is added to ...
Glo 's user avatar
  • 699
25 votes
4 answers
22k views

how to create multilingual static block

I need to create multilingual static block. So far I have created static block with id 'delivery_returns'. I'm calling it in catalog\product\view.phtml like this: $deliveryBlock = Mage::getModel('...
ruuter's user avatar
  • 1,079
24 votes
4 answers
23k views

Something went wrong while saving this configuration: Area is already set

I am unable to apply a new theme in a clean install of 2.2.4. Upading to 2.2.5 does not fix the problem.
Ankush Verma's user avatar
24 votes
4 answers
57k views

How to add translations for new words in Magento?

I'm using English, Spanish and German as three store views for my site. What is the easiest way to add translations for new words? Even if I add new words with the translations it doesn't show in the ...
Sukeshini's user avatar
  • 9,975
23 votes
5 answers
13k views

Managing Magento csv Translation Files

As time has passed, the Magento core team has added more and more default language packs to the app/locale folder. Is there a canon way to manage your own translation files such that they don't ...
Alana Storm's user avatar
  • 44.4k
23 votes
4 answers
45k views

Best Practices Way to Edit Magento Top-Links

Let's say we want to add a shopping cart icon right before the "My Cart" link on Magento's top links (see top links below). What is the best way to do this? Do something to toplinks.php? Do ...
Raphael Rafatpanah's user avatar
21 votes
8 answers
62k views

How to override .phtml files in Magento 2

I want to customize product details page, So it required to override some .phtml files in following locations. So I want to know, how to override .phtml files in vendor\magento\module-catalog\view\...
nuwaus's user avatar
  • 2,344
21 votes
2 answers
7k views

Difference between <remove name=”" /> and <action method=”unsetChild”> in layout

What is the difference between <action method=”unsetChild”> and <remove name=""/>? Both functions are used to remove a block from the layout. Could someone explain with an example?
MeenakshiSundaram R's user avatar
20 votes
2 answers
6k views

What does the "exclude" Tag in Magento 2's view.xml file do

The Magento 2 "blank" theme includes the following tag hierarchy. <exclude> <item type="file">Lib::jquery/jquery-ui-1.9.2.js</item> <item type="file">Lib::jquery/...
Alana Storm's user avatar
  • 44.4k
20 votes
1 answer
12k views

Best way to extend module less found in web/css/source/module, like _minicart.less?

Which is then the best way to extend less files content in <module>/web/css/source/module/, like for instance Magento_Checkout/web/css/source/module/_minicart.less? Assuming that to A) ...
Loreena's user avatar
  • 640
19 votes
3 answers
2k views

Magento Adding a new Language?

I've looked at several pages regarding adding another language support to the Magento cart, however, there seems to be something missing. The usual is to download translation through the admin ...
Karlson's user avatar
  • 747
18 votes
4 answers
19k views

Magento2.1.0 showing error Required parameter 'theme_dir' was not passed while saving product in admin

I am facing this error Required parameter 'theme_dir' was not passed when i try to save the product in admin. I checked the theme configuration it was assigned to the stores. Recently i have upgraded ...
user avatar
18 votes
5 answers
7k views

Magento Displaying appropriate localisation based on Location

I'd like to configure the Magento site to be able to recognize the default language and location of the user and display the site in that language and with appropriate localization. For example: A ...
Karlson's user avatar
  • 747
18 votes
1 answer
3k views

How to hole-punch full page cache without custom module

Our full page cache seems to be based on session. If I open an incognito window with chrome and visit one of the pages, it warms the cache, and the second page load is much faster, however, if I close ...
Jeffrey L. Roberts's user avatar
17 votes
4 answers
88k views

Current Skin Url

I want to get skin URL of my current theme. At present I am working in Magento "rwd" theme. And I am using below code to get skin URL: Mage::getDesign()->getSkinUrl(); This returns me URL http://...
Krupali Mehta's user avatar
17 votes
4 answers
5k views

Magento2 localisation Javascript

A similar question was already asked here: Magento 2 javascript text translations, but Magento updated this translation technique in the beta version. How can I add or update translations used by ...
Silvan's user avatar
  • 1,357
16 votes
5 answers
34k views

Why does my translate.csv and the translation files not work?

I'm trying out a new theme and it seems to not get the translations properly. If I search for the English phrase in my files, I can find: "You have no items to compare.","Sie haben keine Artikel ...
Chris's user avatar
  • 577
16 votes
3 answers
4k views

Magento2 design fallback logic

We already know design fallback logic from Magento 1.x: Current package / Current Theme Current Package / Default theme Base Package / Default theme Now. i want to know What is the design fallback ...
Amit Bera's user avatar
  • 77.7k
15 votes
2 answers
12k views

What is the correct way/approach to modify a Magento template?

Please suggest me the right approach, I want to customize the "EMAIL to Friend" page into pop up window, when user click on the button (email this product). By enabling template hinting, I found out ...
Dimag Kharab's user avatar
15 votes
1 answer
7k views

Make magento core template use my module's translation file

In an extension I'm working on, I have a layout XML added via module's config.xml. This layout has some modifications to the frontend. Some of these blocks, however, belong to Magento core modules. ...
Mridul Aggarwal's user avatar
14 votes
3 answers
10k views

Magento 2 custom theme layout xml and css not working

I created a new theme and it was working fine but after a few days, I realized some things weren't working. default_head_blocks.xml is no longer pulling in any css files that I include (both hosted ...
Amy Ling's user avatar
  • 400
14 votes
4 answers
30k views

How to override blocks in v2.1

I'm trying to override the Topmenu block in Magento 2.1 but can't find any guide to do so. Everything I've found on here and elsewhere either seems to apply only to version 2.0 which appears to use a ...
Michael's user avatar
  • 337
14 votes
3 answers
2k views

Is there a local theme layout XML file other than local.xml?

I've built a theme by creating and editing the following file: frontend/mypackage/default/layout/local.xml I have a store view "site1", and wish to make exceptions on the default local.xml of "...
Gerard Nijboer's user avatar
14 votes
3 answers
12k views

magento 2: 'i18n:collect-phrases' command creates different csv files

php bin\magento i18n:collect-phrases -o "C:\xampp\htdocs\magento\app\design\i18n\xx_YY.csv" -m collects all phrases in the magento application and outputs a csv file with 4 columns: php bin\magento ...
Blackpanther0001's user avatar
14 votes
2 answers
6k views

Correct way to Update a Theme's Parent in Magento 2

In Magento 2, you can specify a parent theme in a theme's theme.xml file. <theme xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Config/...
Alana Storm's user avatar
  • 44.4k
13 votes
7 answers
23k views

How to remove Company field from checkout process in Magento 2?

How to remove Company field from checkout process in Magento 2? I've been looking for the template but have not found it. Update: Is there any way to remove this field via layout or template?
Luis Garcia's user avatar
  • 1,639
13 votes
3 answers
16k views

Magento2: Default to sort by price descending not ascending

Ok so I have my categories sorting by price. Magento 2 defaults this to price ascending. But I would prefer it to be by price descending. Pretty sure I can do this by customising ...
caffeinehigh's user avatar
13 votes
2 answers
11k views

CMS XML Handles for Layout Updates

I've had a few scenarios where I've tried to use the cms handles to update a cms page's layout. For example I was trying to use the cms_index_index handle referencing root and setting the page ...
Mark Weston's user avatar
13 votes
2 answers
5k views

Magento 2: what does i18n mean?

When I started working with Magento 2, that was the first time I came accross this abbreviation so I have no idea what does that word/abbreviation mean ?
Raphael at Digital Pianism's user avatar
13 votes
1 answer
15k views

How to extend the Luma Theme? [duplicate]

I am trying to extend the Luma Theme in Magento 2, But it does not work as expected. I added my Theme, let it extend from Luma, flushed all Caches, Published all Statics and activated the ...
David Lambauer's user avatar
13 votes
1 answer
2k views

Multiple local.xml layout files in a package

Say there are two themes in a package: Base (Set as default) Child (Set as main theme) Both contain a local.xml in the layout folder - Only the local.xml from the Child theme will be loaded, so any ...
Glo 's user avatar
  • 699
12 votes
6 answers
48k views

Magento 2 Translations not working

I'm trying to translate some text in the checkout page: "Provided Zip/Postal Code seems to be invalid." However, when I add the following to frontend/..theme../Magento_Checkout/i18n/en_US.csv and ...
Cake's user avatar
  • 346
12 votes
6 answers
51k views

How to call Owl Slider in Magento2

If we want to add Owl Slider in Magento 1.X then we follow the below steps. Copy owl.carousel.min.js and owl.carousel.js and paste into skin/frontend/pakage_name/theme_name/js Copy owl.carousel.css ...
Dhaval's user avatar
  • 1,695
12 votes
4 answers
15k views

Magento boilerplate / blank / skeleton / naked themes for theme development

Does anyone out there know of a good, clean boilerplate / blank / skeleton / naked theme (unsure of the proper term myself) besides the base/default? Not that it is bad, but sometimes another one may ...
Francis Kim's user avatar
  • 2,973
12 votes
2 answers
10k views

How to add "Empty Cart" button to minicart

How can you add an "Empty Cart" button to the minicart in Magento 2. Is it possible with layout xml?
Holly's user avatar
  • 4,923
12 votes
3 answers
2k views

Translate Maintenance mode per website in multiwebsite-multidomain setup

Translate Maintenance mode per website in multi website-multi domain setup What is the proper way of translating (localisation) Maintenance page in a multi-website and multi-domain environment? ...
versedi's user avatar
  • 2,059
12 votes
2 answers
613 views

How to handle translations with translation bureaus?

I'm wondering what's the best way to realise translations with translation bureaus. Basically I see two ways of doing this: Send them the CSV files. Give them access to a Magento installation for ...
Matthias Zeis's user avatar
11 votes
2 answers
22k views

How to override translate csv files in magento2

Suppose, I want to translate Shop By to Shop in my custom theme using translation file en_US.csv What is the method or procedure to achieve it in Magento2?
Anshu Mishra's user avatar
  • 9,010

1
2 3 4 5
41