title: Foreach Ajax Json - Jquery
body: <p>Can anyone help me </p>
  
  <p>I have a Array</p>
  
  <pre><code>{"stars":[["Chris Pine","Keira Knightley","Kevin Costner"]]}
  </code></pre>
  
  <p>What i'm trying to do is foreach star i want to append a input to a div and foreach star with they're value inside the input this is what i've so far.</p>
  
  <pre><code>$.ajax({
      type: "GET",
      url: 'ajax/get_details.php',
      data: {id: imdb_id},
      dataType: 'json',
      success: function(data) {
          $.each(data.stars, function(i, star) {
              $('#stars').append('&lt;input type="text" id="star" value="'+star+'" /&gt;');
          });
      },
  });
  </code></pre>
  
  <p>Can anyone tell me what i'm doing wrong please thanks</p>