Skip to main content

All Questions

Tagged with
80 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
4 votes
1 answer
2k views

Magento 2: Fatal error: Uncaught Error: Call to a member function getId()

After adding custom module on Server. It's giving below error Fatal error: Uncaught Error: Call to a member function getId() on null in /var/www/html/magento/vendor/magento/module-backend/Block/...
Jackson's user avatar
  • 9,969
4 votes
2 answers
3k views

Magento 2 custom module not loading and it throws error

I am using windows 7. app\etc\config.php <?php return array ( 'modules' => array ( 'Test_Module1' => 1, ), ); ?> When I add My Test_Module1 in app\etc\config.php admin all ...
Niraj Patel's user avatar
3 votes
1 answer
1k views

Magento 2 online refund for custom payment method

I am developing a Magento 2 custom payment module for one of my clients, yet I am now totally blocked in finding a way to process an online refund for any of the created orders. I can't locate the ...
Wagdy's user avatar
  • 31
3 votes
0 answers
105 views

Production mode doesnt load any content for custom module

I have created a custom module in Magento 2. In developer mode it is working well, however same module does not show any content in the production mode of Magento its show only white screen. There is ...
Daniel_12's user avatar
  • 680
3 votes
1 answer
675 views

How to Create Custom Grid Filter Show All "NULL" Values in Specific Column

How can I make a filter for null values of my order ID <column name="order_id"> <argument name="data" xsi:type="array"> <item name="config" xsi:type="array"> ...
Mike121's user avatar
  • 123
2 votes
0 answers
227 views

Magento 2 Add a global js function

i'm trying to extend Magento_Ui/js/lib/core/class, in magento 2.4.3-p1, from a module but my extend js doesn't load in page here is my /view/frontend/web/require-config.js var config = { config: { ...
Weber's user avatar
  • 121
2 votes
0 answers
2k views

Magento 2: Create a custom module for banner slider

I want to create a custom module for banner slider in Magento 2. Could anyone please guide me? Looking forward to hearing from you.
MagentoDev's user avatar
2 votes
1 answer
370 views

Blank Magento Page without error

After enabling the module created, browsing back to the page gives me blank page instead. Viewing the source of the page gives me basic html tags.
MCaneda's user avatar
  • 83
2 votes
0 answers
212 views

Update Store Summary By Checkout Address Country Change

So Basically I want to update my checkout cart summary when user select country from shipping address ,cart price and currency change according to the country he selected in shipping address.
Xain Ijaz's user avatar
  • 105
2 votes
0 answers
67 views

The magento custom sorting functionality is not working

I am creating a Magento module to add a sorting option of a bestseller on the category page. For doing so I have to override few classes in the core. In the beginning, I have created config.xml file. ...
Akshay Vasu's user avatar
2 votes
1 answer
622 views

Move uploaded images to a folder using custom module

I am trying to move the uploaded image to a folder by a custom module. In /var/www/html/magento16f/app/code/local/Custommodule/ReviewRating/controllers/IndexController.php public function ...
inrsaurabh's user avatar
  • 1,676
2 votes
1 answer
2k views

Magento 2: How to define scope in di.xml & Router.php

I'm using Magento 2 CE Version 2.1.0. app\code\Custom\Module\etc\frontend\di.xml <?xml version="1.0"?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:...
Jackson's user avatar
  • 9,969
2 votes
1 answer
2k views

Magento 2: Submitted Form not calling Controller

To continue with the question below Magento 2: How to define Scope For Router.php app\code\Custom\Module\view\frontend\templates\posts\view.phtml <form class="form post reply" action="<?...
Jackson's user avatar
  • 9,969
2 votes
1 answer
252 views

Override a function from app/code/core/Mage/Core/functions.php file into a Custom module

Recently I came across a site which contains some modifications in app/code/core/Mage/Core/functions.php file. I would like to keep code clean and move the changes to custom module in local scope; but ...
ParekhAbhishekN's user avatar
2 votes
2 answers
909 views

How to add active class in top links?

I want to add active class in top links? \app\design\frontend\default\default\template\page\template\links.phtml <?php $_links = $this->getLinks(); ?> <?php if (count($_links) > 0): ...
Ravikumar Patel's user avatar
1 vote
0 answers
210 views

Magento 2 custom routing frontend not working (100 router match iterations)

I have used this url to change it but i am keeping getting the same erros https://magento.stackexchange.com/a/209478/96152 i have a custom routes.xml <?xml version="1.0"?> <config ...
Tj1997's user avatar
  • 47
1 vote
0 answers
101 views

How to add custom category rule tab in form in admin side in magento 2.3.5

Hello Friends I want to add new tab in form for applying rule for specific category in magento 2.3.5.
Deep Shah's user avatar
  • 577
1 vote
0 answers
868 views

Magento 2 : place order after a click on place order button in custom payment module

I'm a beginner on Magento. I try to create a custom payment module. All work fine but when I click on the "place order" button on the checkout page, the order is not add to the orders list ...
Mr T's user avatar
  • 11
1 vote
2 answers
1k views

Magento 1.9.4.3 Custom Column Filter not working

I have a custom column on my sales order grid showing the ordered items sku's. Done by following the guide here. It worked well in previous versions but no longer does work correctly in 1.9.4.3. When ...
Vaishal Patel's user avatar
1 vote
0 answers
597 views

Add message on Checkout Page in Magento 2

Already add my custom module to Disable Payment method on the Checkout Page based on Product Attribute in Magento 2 Now I want to show the message to customer on Checkout Page if COD is Inactive by ...
Apoorv Gupta's user avatar
1 vote
1 answer
53 views

Magento 1.9 Custom Module Error

I am a noob of Magento 1.9. I have these custom module files: app/code/local/mypackage/custommodule/block/mymodulename.php app/code/local/mypackage/custommodule/etc/config.xml app/code/local/mypackage/...
filb's user avatar
  • 11
1 vote
1 answer
292 views

Custom modules disappeared after 2.2.9 upgrade

All custom modules have disappeared after upgrade to 2.2.9 from 2.1.9. When I run bin/magento setup:upgrade, last message is "Nothing to import." but the custom modules are not enabled and not added ...
Mathieu's user avatar
  • 63
1 vote
0 answers
297 views

Shipping method restrictions by category programmatically magento 2

I want to add Shipping method restrictions by specific category in custom shipping method
Sagar Patel's user avatar
1 vote
1 answer
2k views

Magento2 : Save Button Not Working in Admin Form Custom Module

I am Working on A magento 2 custom Module i have a Form as well a Product Grid in my form so i created tabs using block but Whenever i click on save button gives me Javascript Error TypeError: $....
User 69's user avatar
  • 145
1 vote
1 answer
289 views

How to Remove/Hide unwanted address fields

I've looked everywhere for an answer to my question. I'm pretty new to Magento. For the shipping-address page of my site, I need to have all of the fields removed. My plan is to have them removed ...
Parkour1309's user avatar
1 vote
1 answer
448 views

I want to run an Event Observer once after my custom module is installed

Is there a way to run a function (to call an api) once after a module is installed? It could be during admin page load or in the install script. But i wish to run only once. Thanks
subhas's user avatar
  • 53
1 vote
0 answers
77 views

Call a custom phtml file to particular section Magento ver 1.6 to 1.9

I created a custom module (For Magento ver 1.6 to ver 1.9 ) in which i show custom phtml file and insert custom js and css as well, I included it to two pages only with particular section i.e footer ...
inrsaurabh's user avatar
  • 1,676
1 vote
2 answers
513 views

Custom Module not working | Custom Code working fine

I am trying to get my custom module working and I am not sure where I am wrong. Here is my app/etc/[namespace]_CustomPriceRevert.xml: <?xml version="1.0"?> <config> <modules> ...
Greg's user avatar
  • 2,749
1 vote
0 answers
477 views

Set action to custom module admin Button

I created a custom module, with a button in System > Configuration. Clicking on this button should call a function and then inform the user about the function's results (I suppose by reloading the ...
zekia's user avatar
  • 660
1 vote
0 answers
65 views

AJAX Form custom module

I am new to Magento, still learning how things work here. I am planning to create a custom module, which would submit a form on a product page through AJAX. It would let the client ask about product ...
Kuba M's user avatar
  • 33
1 vote
0 answers
73 views

How to make custom php in home page

I need to make a website, let's call it shop.com, that manages other providers on subdomain (p1.shop.com, p2.shop.com...). So, I successfully make all the websites works, but now I need to make shop....
Jeremie CIESLARCZYK's user avatar
1 vote
1 answer
2k views

Magento 2 - how to get custom model from custom module

In Magento 2, how can I get a custom model that is created in a custom module (not a Magento 2 native module)? I know I can use object manager for getting and creating, and I know how to do this for ...
Vladimir Despotovic's user avatar
1 vote
0 answers
489 views

magento 2.1 grid on custom tab of admin product edit page

I am trying to create a grid that should be shown on clicking a custom tab of admin catalog edit page. 1. Created catalog_product_new.xml <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-...
SPK's user avatar
  • 183
0 votes
1 answer
35 views

Add fee to Payment method

I'm trying to add an extra fee to the order when the payment method is Cash on delivery and the shipping country is Greece. I have created the following files: app/code/HectorCustom/CodFee/...
Dimitra's user avatar
0 votes
1 answer
103 views

error filtering templat: Template file 'header.html' is not found in mail in magento 2.4.6

Send invoice email to custom mail address in magento 2 but create custom email template but face this issue in magento 2.4.6 app/code/YourVendor/YourModule/etc/email_templates/invoice_email_template....
Ravindrasinh Zala's user avatar
0 votes
0 answers
48 views

how to make custom tier price in add product feature of magneto 2

I want to make a tier price programmatically for quantity-based shipping prices like the screenshot below, can anybody help me in developing this feature
Syeda's user avatar
  • 13
0 votes
1 answer
84 views

create custom module, get existing module configuration

I would like to create a custom module, I want to get used to the vendor/magento/module-ups/ module, and use the same config in my custom module, such as userID, password, access key. how can I ...
Paul Fan's user avatar
  • 658
0 votes
2 answers
130 views

Why is this code slow

We have a custom module to show images from sw3 on the product page, so the main image and any gallery images. The code works but going from a list page to the PDP is very slow and when I disable this ...
rodolphesalis's user avatar
0 votes
0 answers
149 views

How to double the items in the cart by updating the quantity in the product cart page?

Double the value in the cart by updating the quantities.
kks's user avatar
  • 19
0 votes
0 answers
20 views

Can anyone resolve this issues? Two buttons (add to cart )are coming with the disabled mode

I need to apply the code for the add to cart button but it is coming in disabled mode hence unable to do the required changes.strong text
kks's user avatar
  • 19
0 votes
2 answers
750 views

How to get the template Id in controller? template Id is returning NULL for the custom template in the custom module

Index.php <?php namespace Eaglerocket\Customquote\Controller\Index; use Magento\Framework\App\Action\Action; use Magento\Framework\App\Action\Context; use Magento\Framework\...
kks's user avatar
  • 19
0 votes
1 answer
23 views

This is the error I am facing while sending the mail function

<?php /** * * Copyright © 2016 Magento. All rights reserved. * See COPYING.txt for license details. */ namespace Eaglerocket\Customquote\Controller\Index; use Magento\Framework\App\Action\...
kks's user avatar
  • 19
0 votes
0 answers
25 views

If trying to get the current product info then pop up model is not opening

/Blockname.php/ <?php namespace Eaglerocket\Customquote\Block; use Magento\Framework\View\Element\Template; class Blockname extends Template { protected $_registry; public function ...
kks's user avatar
  • 19
0 votes
1 answer
1k views

Unable to edit integration

We recently cleaned up our Magento 2.4.2 store so we had no generic users. Since we did this we noticed one of our integrations shows as inactive and we are unable to Activate or edit the integration, ...
P Walker's user avatar
0 votes
3 answers
606 views

How to disable custom plugin in admin

I have created a custom module to disable free shipping based on some conditions. I have to used Custom/ShippingRule/Plugin/Magento/Shipping/Model/Shipping.php to do the functionality. It is working ...
Ramesh KR's user avatar
  • 886
0 votes
1 answer
138 views

Module to Add/Manage Custom Fields?

Is there a Magento2 module similar to Wordpress' Advanced Custom Fields that allows admins to add and manage custom fields to CMS and other pages through the GUI?
Sam's user avatar
  • 163
0 votes
0 answers
57 views

Store external API expire time in Custom Module

I use ajax to get the access token from the external API. How can I store the expired time across the site and the ajax only call again when the session expired? test.js /helloworld/index/display is ...
Tony Le's user avatar
0 votes
1 answer
535 views

How to add a frontend search box functionality for a custom table grid magento2

I have created a custom module and get data in the list format, now I want to add search functionality on the list view, so how can I add that?
Hemangi Patel's user avatar
0 votes
0 answers
145 views

Block is not getting called in custom module - Magento 2.3

I created a custom module to list all categories in a custom page. But the associated block is not getting called in the layout file. I can see the controller function is getting executed and page ...
Sayanth's user avatar
0 votes
0 answers
51 views

What are some simple custom modules to play with Magento 2?

I'm learning Magento 2 modules. I would like to create custom modules from beginner level to advanced. Can you please tell me what are simple concepts that can be created as a module in Magento 2? ...
MagentoDev's user avatar