I have a similar article about this on StackOverflow, but maybe my misunderstanding is more significant. I have an Index () action, and the index is viewing its rendering. From the Index () view, depending on the pressed button, [HttpPost] Index () or [HttpPost] Search () needs to be called, because I am sending some data. The only way to post different actions is to use jQuery? If jQuery is the only way if my actions return views (full HTML pages), do I need to clear the entire document element from $ .post and fill it with my html views? I'm new to this, thanks a ton!
@using (Html.BeginForm())
{
<input name="startDate" type="text" size="20" class="inputfield" id="datepicker" />
<a href="#" id="apply_button">...</a>
<a href="#" id="go_button">...</a>
}
public ActionResult Index(string lang)
{
return View();
}
[HttpPost]
public ActionResult Index(string lang, string startDate)
{
return View();
}
[HttpPost]
public ActionResult Search(string lang, string startDate)
{
return View();
]