I am using Luma default theme in Magento 2 and I want to create a new phtml file and call it from CMS.

Can anyone tell me in which path i need to create my file and how to call it form CMS?

I trying to create in this path: C:\xampp2\htdocs\medipoint\vendor\magento\theme-frontend-luma\Special_Price\special_price.phtml

and call it in this way:

{{block class="Magento\Framework\View\Element\Template" name="myname" template="Magento_Theme::Special_price/special_price.phtml"}}

but it doesn't work.

  • is Magento_Theme your module name ? – Priyank Oct 21 '16 at 8:31
  • you have to first create your theme – Rakesh Jesadiya Oct 21 '16 at 8:40
  • i am new in magneto so i don't know. i am using default Luma theme – Alin Lupoiu Oct 21 '16 at 8:40
  • Have you create new theme? – Rakesh Jesadiya Oct 21 '16 at 8:40
  • no. actually i want only to create a single page in my current theme and use it in cms. is that possible? – Alin Lupoiu Oct 21 '16 at 8:42

Working Completely.

{{block class="Magento\Framework\View\Element\Template" name="myname" template="Magento_Theme::Special_price/special_price.phtml"}}

But file must be locate in correct path


If you are using Luma theme then file path :


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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