The Stack Overflow podcast is back! Listen to an interview with our new CEO.

Questions tagged [class]

A template for creating new objects that describes the common state(s) and behavior(s). NOT TO BE CONFUSED WITH CSS CLASSES. Use [css] instead.

29 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
4
votes
0answers
163 views

Problem with block override in Magento 2

Note: Before marking the question as duplicate or off-topic, please read the question carefully. Scenario: I have to show custom column in the admin grid of a custom extension. So I used override ...
3
votes
1answer
863 views

Magento2 rewrite: product resource collection class does not effect on functions

I have rewrite catalog product resource collection Magento\Catalog\Model\ResourceModel\Product\Collection. Class override successfully but functions override is not working. Suppose, i want ...
2
votes
0answers
26 views

Add css class to item on checkout xml

how can i add a css class eg.: class="myClass" to an item on checkout xml? for example <item name="after-place-agreements" xsi:type="array"> <item name="component" xsi:type="string">...
2
votes
0answers
28 views

Can Magento 2 Proxies be used to handle non existing class

I am building an extension which is dependent on multiple third party payment gateways. So I have created a special service class which gives the respective payment gateway class object depending on ...
2
votes
2answers
499 views

how to override any .phtml or class file in magento2 using custom module?

Well I have an idea to create custom module in magento2 but when it comes to override code functionality I stucks. for example I have to override this file default.phtml in /vendor/magento/module-...
1
vote
2answers
18 views

How zend libs file(Rewrite Zend_Pdf_Resource_ImageFactory) class in Magento 2

i am trying to override Zend libs class like magento2 using preference My di.xml code is <?xml version="1.0"?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:...
1
vote
0answers
31 views

Magento 2 - How to add video icon in dot if the gallery has video?

I want to add video-icon class in dot if the gallery has video.
1
vote
1answer
245 views

Magento 2.2.4 - Couldn't override block class

I am trying to override the Magento\ConfigurableProduct\Block\Product\View\Type\Configurable class. I have added a preference in app/code/vendor/module/etc/di.xml file. <config xmlns:xsi="http://...
1
vote
0answers
21 views

How should I deal with multiple classes used in the same algorithm in Magento2?

I have a situation where I am building a module for Magento2 with 3 Models that kind of interact with each other depending on the situation. I tried to inject the classes withing them selves but that ...
1
vote
0answers
519 views

Compile: Extra parameters passed to parent construct: $context

This has been asked a few times I know and I studied all of them and I also get the ieda what went wrong. However I cannot adapt those solutions to my issue. I have a Class Post which extends \...
1
vote
0answers
38 views

magento 2 : Equivalent class for Adapter Product and Parser abstract

What is the equivalent class for the same in Magento2 Mage_Catalog_Model_Convert_Adapter_Product Mage_Eav_Model_Convert_Parser_Abstract
1
vote
0answers
43 views

Changes to a .php file not getting compiled

I made some changes to the file app/code/core/Mage/Checkout/Model/Observer.php. However those changes are not reflecting in includes/src/__checkout.php in the Mage_Checkout_Model_Observer class.(After ...
1
vote
0answers
83 views

How to instantiate my new class and methods

I'm looking to trigger anything on a /admin/customer/edit just to know it's working.. an echo or print.. I have this code below. app/code/community/YourModule/etc/config.xml <global> <...
1
vote
1answer
806 views

Magento model extension experiment, return: “class does not exist”

trying to create a new model class to be used as a source model for the admin configuration setting of a new module, I got the following message: Class Makke\GroupOrders\Model\Config\Source\Sort ...
0
votes
0answers
28 views

Class does not exist ReflectionException keeps coming back

We have a Magento 2.1.5 project. We are getting strange errors. At some moment the website works properly and the next day we get an error when we login to the admin. We get the following error: ...
0
votes
1answer
20 views

Error in magento 2.3 Class Does Not Exist in backend and frontend

I upload my magento 2.3 on my server, so when i navigate in the frontend the navbar is disappeared see the photo so when change the mode to developer, to see the error in backend output print this ...
0
votes
0answers
56 views

Magento 2.2.8 : Class Magento\Ui\Block\Wysiwyg\ActiveEditor does not exist

I have updated from version 2.2.7 to 2.2.8 now I have this error Class Magento\Ui\Block\Wysiwyg\ActiveEditor does not exist in the back-end when I try to access for example to Categories page. ...
0
votes
2answers
56 views

Why does magento 2 use hard coded “Factory” class?

As I've checked in Magento 2.3.1 Sales module there is one hardcoded Factory file in below path: vendor/magento/module-sales/Model/ResourceModel/Order/CollectionFactory.php And in Cms module there ...
0
votes
0answers
27 views

Unable to override model class, only this file has problem

I am overriding Worldpay Model class that create xml request file. <?xml version="1.0" encoding="UTF-8"?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:...
0
votes
1answer
70 views

Create custom payment gateway in Magento 2?

Which class we need to extends,implement interface and method use when create a custom payment gateway.
0
votes
1answer
33 views

RewardspointsFactory class does not exist

Please anyone review my code. Facing this error. Exception #0 (ReflectionException): Class Sugarcode\Test\Model\ResourceModel\Test\RewardspointsFactory does not exist Exception #1 (ReflectionException)...
0
votes
0answers
24 views

How can we apply custom class for landing page and product page?

How can we apply custom class for landing page and product page? Ex: i want 100% width on landing page and custom width on product page
0
votes
1answer
69 views

Error when trying to ban url with Varnish Cache

I've updated the EcomDev_Varnish module to it's latest version and it seems I've gotten everything properly running, but as a test I tried following command: php ecomdev-varnish.php cache:ban -v ...
0
votes
1answer
28 views

Added function to class core not returning anything

I want add a function to the core class. To do this I have added a file to extend the class core but when I call the function it's returning nothing.
0
votes
0answers
225 views

Overriding a class : Mage_Catalog_Block_Product_View_Type_Configurable

I want to override Mage_Catalog_Block_Product_View_Type_Configurableclass. I have created one module : Ved_Catalog Here are my module files: Code from config.xml : <config> <global> ...
0
votes
1answer
83 views

access parent class on class overwrites in magento, from a sibling

It is required to overwrite customer_resource class. I added required config.xml options for resource rewriting, but when overwritten class method calls parent class method from itself, it actually ...
0
votes
0answers
143 views

Can't change Customer's Customer Tax Class

I have this weird problem where I can't change a customer's Customer Tax Class through the admin interface. It keeps jumping back to Retail customer. So when I select a different Customer Tax Class ...
0
votes
0answers
445 views

How to Fetch Product child Function Outside External file in Magento

I want to fetch all child function of magento outside of it.I have CORE_PHP with some jquery functionality and php function,In that Files,I need to add Product Children Function of magento into that ...
0
votes
1answer
808 views

Magento 2 Class Catalog\Model\Product\Attribute\Backend\Media does not exist

When trying to edit or add a new product on the backend I receive the following error Class Magento\Catalog\Model\Product\Attribute\Backend\Media does not exist. It stops me from editing or adding ...