How to Call Phtml file on CMS Page or CMS Block – Magento2: Sometimes we need to add dynamic content in our CMS Block or CMS pages. For that, Calling PHTML file is best idea. So today we will learn how to add or call PHTML file on any CMS page or CMS block.
First login to your Magento admin dashboard. Open any CMS page or CMS block where you want to call PHTML and add the below code.
1 |
{{block class="Magento\Framework\View\Element\Template" template="Webiators_CustomChanges::custom.phtml"}} |
Hit 5 Stars if you find this post helpful
0 (based on 0 Reviews)