0

Which is the quickiest way to add/call a phtml file in homepage (only) in magento 1 (custom theme) ?

I am not sure about magento 1, so any thoughts would be appreciated.

1 Answer 1

0
  1. From cms page

    {{block type="core/template" template="brand/brand.phtml"}}

in which brand/brand.phtml is the path inside templates folder of you theme e.g app/design/frontend/active_theme/default/templates/brand/brand.phtml

  1. Call another phtml from one phtml

    <?php echo $this->getLayout()->createBlock('core/template')->setTemplate('brand/brand.phtml')->toHtml(); ?>

Both ways are correct and efficient in magento.

Your Answer

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

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