title: Jquery/ajax Looping SetTimeout
body: <p>Hi I'm stuck on my setTimeout function. What i'm trying to do is to loop my setTimeout for my retrieve conversation function.. I have tried this on setInterval but using setInterval is a badnews for my application which is why I switch to setTimeout.. But I cant seem to figure out how to make the setTimeout work again after its done loading.. here is what I have tried so far and still trying to make it work at the moment..</p>
  
  <p>Javascript:</p>
  
  <pre><code>id = setTimeout(function()
  {
      $.ajax(
      {
          url: "includes/handlechat.php",
          type: "GET",
          data: data,
          dataType: 'json',
          success: function(result)
          {
              $("#clog").empty();
              $.each(result, function(rowKey, row) 
              {
                  $("#clog")
                      .append('&lt;p &gt;&lt;h4&gt;'+ row.username +':&lt;/h4&gt;' + row.message_content + '&lt;/p&gt;' );
              });
          },
          complete: function () 
          { 
              clearTimeout(id);
          }
      })
  }, 1101);
  </code></pre>
  
  <p>Any tips or suggestion ?</p>