title: How do I pass an array of integer into spring controller?
body: <p>script <code>Array</code> of <code>int</code> and I wish to pass into <code>Spring Controller</code>. but I keep getting </p>
  
  <pre><code>400 bad request.
  </code></pre>
  
  <p>if my <code>js array</code> is</p>
  
  <pre><code>array = [1,2,3,4]
  array -&gt; 400 bad request
  JSON.Stringify(array) -&gt; I will get [1,2,3,4]
  
      $.ajax({//jquery ajax
                  data:{"images": array},                
                  dataType:'json',
                  type:"post",
                  url:"hellomotto"
                  ....
              })
  </code></pre>
  
  <p>when I loop the <code>string List</code>.. the first element will be <code>'[1'</code></p>
  
  <pre><code>@RequestMapping(value = "/hellomotto", method = Request.POST)
  public void hellomotto(@RequestParam("images") List&lt;String&gt; images){
   sysout(images); -&gt; I will get [1,2,3,4]
  }
  </code></pre>
  
  <p>public void</p>
  
  <p>May I know how can I do this properly? I have tried different combination</p>