I have set template using the following code


This calls the template file from the following folder frontend/base/default/template/catalogsearch/for‌​m.mini.phtml.

How can I call this from my custom theme (i.e.) frontend/customtheme/default/template/catalogsearch/for‌​m.mini.phtml ?

1 Answer 1


if you have configured your package/theme correctly in backend (at System > Configuration > Design), then Magento will automatically take your phtml file from your package\theme if you have defined your phtml file correctly there.

Magento uses a callback mechanism to fetching the correct file. It first look for a theme file in the configured package/theme directory, then the default theme directory (if any) and at last in the base/default directory.

So your file is taking from base/default directory means, you didnt defined catalogsearch/for‌​m.mini.phtml in your theme directory correctly. So check again the template file path and then clear the cache.

  • Hi Rajeev, Thank you for your comment, However I have declared correct package name on configuration and I have file on my customtheme folder
    – Dev
    Apr 6, 2015 at 8:02
  • Hi Rajeev, I just checked the error log and found the solution. this was the error 'Not valid template file:frontend/base/default/template/catalogsearch/for‌​m.mini.phtml'. I just copied the code from some site and this causes the spell mistake. ;-)
    – Dev
    Apr 6, 2015 at 9:08

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.