0

Actually, I want to add contact us form and functionality programmatically in Magento 2 custom theme in frontend.

0

In Homepage or any block or cms page just add below shortcode for getting contact us form.

{{block class="Magento\Contact\Block\ContactForm" name="contactForm" template="Magento_Contact::form.phtml"}}

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.