0

I want to override an xml file of an extension module into my custom module, how can I do it?

3
  • Which file you want to override?
    – Impunkj
    Jun 4, 2018 at 9:39
  • @YDF , if the below solution works for you than you can mark this as Answer. Thanks.
    – xMageStore
    Jun 4, 2018 at 10:05
  • @Impunkj it's algolia_search_handle_prevent_backend_rendering.xml file
    – YDF
    Jun 4, 2018 at 10:43

1 Answer 1

1

You can do like this in your custom Module:-

Your_VendorName\Your_ModuleName\etc\di.xml

<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
     <preference for="Magento\Framework\View\Element\Html\Select" type="Your_VendorName\Your_ModuleName\Model\Framework\View\Element\Html\Select" />
</config>
2
  • @YDF , if this solution works for you than you can mark this as Answer. Thanks.
    – xMageStore
    Jun 4, 2018 at 10:02
  • @xMageStore, the solution you suggested doesn't work!
    – YDF
    Jun 5, 2018 at 6:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.