0

I have set up a custom theme in Magento admin panel under "Design" tab

I can now put my custom code in

 \app\design\frontend\default\MYTHEME\template 

instead of

 \app\design\frontend\base\default\template 

I would like to do the same for the admin panel code. In other words, I would like to selectively replace vanilla code in this directory

 \app\design\adminhtml\default\default\template 

with custom code, likely in this directory

 \app\design\adminhtml\default\MYTHEME\template 

Magento does not seem to recognize this automatically.

        • edit - - -

For the sake of maintainability it would be beneficial to have a global over-ride like we have in 'frontend'. Over-riding module by module in the module layout may not be obvious to next person that looks at the code.

2
  • stackoverflow.com/questions/14448983/… Commented Feb 6, 2013 at 1:11
  • I was reading this and other similar questions. Your solution recommends a module by module override. for the sake of maintainability, is an "all module" solution possible? Commented Feb 6, 2013 at 1:36

2 Answers 2

2

Try

In /app/code/local/MageIgniter/AdminThemeAndMod/etc/config.xml

<?xml version="1.0"?> <config> <modules> <MageIgniter_AdminThemeAndMod> <version>0.1.0</version> </MageIgniter_AdminThemeAndMod> </modules> <stores> <admin> <design> <theme> <default>mageigniter</default> </theme> </design> </admin> </stores> </config> 

In /app/etc/modules/MageIgniter_AdminThemeAndMod.xml

<!-- /app/etc/modules/MageIgniter_AdminThemeAndMod.xml --> <config> <modules> <MageIgniter_AdminThemeAndMod> <active>true</active> <codePool>local</codePool> </MageIgniter_AdminThemeAndMod> </modules> </config> 

Then add your newly add/update files to

/app/design/adminhtml/default/mageigniter/layout/ /app/design/adminhtml/default/mageigniter/template/ /skin/adminhtml/default/mageigniter/ 
Sign up to request clarification or add additional context in comments.

3 Comments

OK. What are we doing here? We create a new module in MageIgniter/AdminThemeAndMod with nothing but a config.xml file. DO all admin files have to go in /mageigniter? - or can it be used for just changes and new phtml and xml?
Just like the frontend, you only need to add the files you modify
The settings specified here are redundant; merely specifying <default>mageigniter obviates the type-specific declarations.
0

for "/app/etc/modules/MageIgniter_AdminThemeAndMod.xml", you mean -

<?xml version="1.0"?> <!-- /app/etc/modules/MageIgniter_AdminThemeAndMod.xml --> <config> <modules> <MageIgniter_AdminThemeAndMod> <active>true</active> <codePool>local</codePool> </MageIgniter_AdminThemeAndMod> </modules> </config> 

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.