How would I get both param1 and param2 to my controller, I tried like this but only param1 gets passed.
@using (Ajax.BeginForm("Index", "Controller", new { param1 = 0 }, new AjaxOptions { UpdateTargetId = "Target", InsertionMode = InsertionMode.Replace, OnFailure = "error" }))
{
<input type="submit" name="param2" value="1" />
//more buttons
}
public ActionResult Index(int param1, int param2)
{
//do something
}
Is not it working ??