i wanted some customization in admin panel so i have made changes in
1) "app/code/core/../system.xml file its working fine.
But I don't want to change code inside core folder. Because of my version change.
So i like to move that file into my local folder but its not working
2) "app/code/local/../system.xml" files is not working
Can anyone please guide me how to override system.xml file?
Thanks
Best Answer
For the
system.xml
files it doesn't work like it does for class files. Thesystem.xml
files are collected from the active modules of Magento. Just copying one inlocal
folder it doesn't mean it's in a module, because the module declaration file still says that the module belongs to thecore
codepool.If you want to add new fields to a section or override some of the fields you need to create you own module.
Here is an example of how you can add a new field in the section
Catalog->Frontend
and how you can override one in the same section.Let's say that your module is called
Easylife_Catalog
.You will need the following files:
app/etc/modules/Easylife_Catalog.xml
- the declaration fileapp/code/local/Easylife/Catalog/etc/config.xml
- the configuration fileapp/etc/local/Easylife/Catalog/etc/system.xml
- system->configuration fileLet's say you want to change the
List Mode
field to be available only at global level (no website and store view level). The setting path iscatalog/frontend/list_mode
. Then thesystem.xml
will look like this:Now let's say you want to add a new field called
custom
in the same config section. Now the xml above becomesI don't know if there is a method to remove some field from the configuration using this method. I looked for it but didn't find anything.