0
votes

I am using default magento luma theme in Magento2 .

I would like to change in this file and need to override in app/code folder

/vendor/magento/module-theme/view/frontend/templates/html/header.phtml file.

I also want to change in existing custom module template file to override.

app/code/company/modulename/view/frontend/templates/view.phtml

I have tried lot of method but not working.

Please suggest.

Regrads Vimal

2

2 Answers

0
votes

Please Follow Below Instructions :

1.>> You want to override any Vendor/Extension/Module .PHTML file. You need to create your own theme. after that, you will override .PHTML file.

2.>> Click here to know how to create theme https://www.cloudways.com/blog/create-custom-theme-magento-2-part-1/

3.>> app/design/frontend/Custom Package Name/Custom Theme Name/Magento_Theme/templates/html/header.phtml

0
votes

Please Follow Below Instructions :

  1. You want to override any Vendor/Extension/Module .PHTML file. You need to create your own theme. after that, you will override .PHTML file.

  2. Click here to know how to create theme http://devdocs.magento.com/guides/v2.1/frontend-dev-guide/themes/theme-create.html

  3. For Override Core Phtml file (Exp : - If you want to header.phtml file of module_theme (module_theme is replaced by Magento_Theme) app/design/frontend/Namespacename_Theme/Custom_Theme_Name/Magento_Theme/templates/html/header.phtml)

  4. For Override Custom Phtml file app/design/frontend/Namespacename_Theme/Custom_Theme_Name/Custom module namespace_Modulename/templates/custom.phtml)