I made custom layout page for CMS page and i want to add Contact form in that CMS page.

For this i am using following code in CMS page content :

{{block type=”core/template” name=”contactForm” form_action=”{{store direct_url=”contacts”}}/index/post” template=”contacts/form.phtml”}}

But it showing code in front side not showing contact form. Please help me.

Thanks in advance

  • use this in your cms page {{block type="core/template" name="contactForm" form_action="/contacts/index/post" template="contacts/form.phtml"}}
    – Magento 2
    Sep 11, 2015 at 5:21
  • I had also used that but not working always showing entered code not form.
    – Chandresh
    Sep 11, 2015 at 5:23
  • can you please share your code(contact form code)
    – Magento 2
    Sep 11, 2015 at 5:26
  • You can get help from here,I have also used same:- <br> inchoo.net/magento/contact-form-in-magento <br> or <br> support.createhosting.co.nz/…
    – Arunendra
    Sep 11, 2015 at 5:26

2 Answers 2


Use the below code in your CMS page in Magento.

{{block type="core/template" name="contactForm" form_action="/contacts/index/post" template="contacts/form.phtml"}}

Let me know if you face any further query with this.

  • I am using this code with multiple store and multiple sore views so i need to store code before "contacts/index/post" like "eu_en/contacts/index/post" but it will be not good put static store code for all store. Please provide me if any other solution.
    – Chandresh
    Sep 14, 2015 at 7:24

try this i think it " problem..

{{block type="core/template" name="contactForm" form_action="{{store url='contacts'}}/index/post" template="contacts/form.phtml"}}
  • 1
    your given code is also not working it is only displaying /index/post" template="contacts/form.phtml"}}
    – Chandresh
    Sep 14, 2015 at 6:59
  • update check it now... Sep 14, 2015 at 7:58

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.