在cms页面中调用phtml文件无效Magento2

时间:2016-08-22 11:31:42

标签: php magento module magento2

您好我正在构建一个模块,我需要在cms页面中调用我的视图文件 位于app\code\Eecom\Atc\view\frontend\templates\atc\index.phtml

在cms中我将此文件称为

    {{block class="Magento\Framework\View\Element\Template" 
template="atc/index.phtml" }}

我也试过

{{block class="Magento\Framework\View\Element\Template" template="Eecom_Atc::atc/ndex.phtml"}}

但两者都不起作用 请建议我在哪里做错了 感谢

1 个答案:

答案 0 :(得分:1)

嗨,下面的一个正在工作

 {{block class="Magento\Framework\View\Element\Template" template="Eecom_Atc::atc/ndex.phtml"}}

问题是缓存刷新。