Umbraco 7 Submitting Forms using post and get

In Umbraco, we have 2 ways to submit form data, we can use either RenderMvcController or SurfaceController, ideally, you would use the Surface Controller to post a contact form or user login details and RenderMvcController for a search form.

This blog will show how you can use both ways to submit a form and also includes Html.BeginUmbracoForm which you will find only allows both post and get methods.


To run this example, I have created a helper class library, a model class library and a core class library.

The core class library is where the controllers are, I prefer this way of coding as I believe that the UI should not contain any controllers.

The helper class has the test data and the model class contains the model.

Below is how the site structure is laid out.

Summary

Thank you for reading this blog about submitting forms in Umbraco 7, I hope you found it helpful.

Leave a comment

*
*

Comments

Learning Umbraco, helpfull post

Comment posted by Albrecht Schneider on 18 Nov 2019 10:16

Hi Albrecht thanks for the post, good to hear you found it helpful