title: JQuery Post data to MVC Action Method?
body: <p>All I'm trying to do is to pass an array of strings/ints to mvc action method.
  But the data always comes back as null, what am I doing wrong?</p>
  
  <p>MVC Controller</p>
  
  <pre><code>[HttpPost]
   public ActionResult MyAction(List&lt;string&gt; ids)
   {
     // do something with array
     // But it's null
        return View();
   }
  </code></pre>
  
  <p>JQuery</p>
  
  <pre><code>$.post("/MyController/MyAction", JSON.stringify(ids), function () { alert("woohoo"); }, "application/json");
  </code></pre>
  
  <p>Data being posted to action result</p>
  
  <pre><code>["156"]
  </code></pre>