title: After all the data successful load from Ajax, then I want to use another ajax to change the image loading.gif
body: <pre><code>$.ajax({
              type: "POST",
              url: url,
              contentType: "application/json; charset=utf-8",
              dataType: "json",
  
              success: function(response) {
                 for (var i = 0; i &lt; response.posts.length; i++) {
                        post_id = posts[i].id;
                        title = post[i].title
                        thumbnail = posts[i].thumbnail_url;
                        $('#post').append('&lt;p&gt;'+title+'&lt;/p&gt;')
                        $('#post').append('&lt;img id="'+post_id+'" src="/loading.gif"&gt;)
                 }
              }
         })
  </code></pre>
  
  <p>For the image, I want after all the data successful load from Ajax, then I want to use another ajax to change the image loading.gif to the thumbnail_url.
  Is there any better way, or anything please kindly help me..!</p>