title: MVC button click call POST Action method
body: <p>How can I call an MVC action method with complex parameters, like the below, from a button click event?</p>
  
  <pre><code>[ValidateInput(false)]
  [HttpPost]
  public ActionResult Export(ViewModel vm)
  {
    // some logic
  }
  </code></pre>
  
  <p>I have made it a POST action because I need to pass HTML tags of the current page on which the button is to the action method which is too long. I have tried this but this its for a GET operation </p>
  
  <pre><code>&lt;input type="button" value="Detail" onclick="location.href='@Url.Action("Export", "Report")?html=' + $('#test').html()" /&gt;
  </code></pre>