Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
I am new to ASP.Net MVC integration in Umbraco.
We have created a controller inherited from RenderMvcController and has define the following method in that controller
public System.Web.Mvc.ActionResult Index(RenderModel model)
//Here POCModel is the model implementing IPublishedContent interface.
POCModel obj = new POCModel(model.Content, Umbraco);
return base.Index(new RenderModel(obj));
It is working fine as all the properties initialized in the POCModel is getting written on the view. Now we are thinking of creating the form on that page and submitting the data using that form and collecting the data in the action of the controller which is inheriting from RenderMvcController. When we submit the data using the form the call is getting send to the Index action only and not to the action which we have defined. Here is the action which we have defined.
public void DoSomeAction(POCModel obj)
Here is the form which we have defined in the Template
@using (Html.BeginForm("DoSomeAction", "FirstPocforMvcsite"))
//Here TestProperty is the property name defined in POCModel
<input type="submit" value="Submit" />
Please help me on this.
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted