title: creating complex JSON using BasicNameValuePair
body: <p>How can I create this JSON using ArrayList for posting json in Android</p>
  
  <pre><code>{
  "user" : 
      {
          "nickname" : "nickname6",
          "password" : "1234",
      }
  }
  </code></pre>
  
  <p>I get only to a flat JSON</p>
  
  <pre><code>    ArrayList&lt;BasicNameValuePair&gt; nameValuePairs = new ArrayList&lt;BasicNameValuePair&gt;();
  
      nameValuePairs.add(new BasicNameValuePair("nickname","nickname6"));
      nameValuePairs.add(new BasicNameValuePair("password", "1234"));
  </code></pre>