title: refresh page using jquery ajax
body: <p>I have a web application where I am showing user comments on a page with its posting time. Since there are comments posted regularly so I need to update the comment posting time after every 1 minute. For this purpose I am using jquery ajax to update the time from db. My code is this:</p>
  
  <pre><code>&lt;script type="text/javascript"&gt;
  
   setInterval("UpdateTime()", 60000);
  
  
  function UpdateTime() {
      var id=$('#hdID').val();
      $.ajax({
          type: "POST",
          url: "mypage.aspx/UpdateTime",
          data: "{'id':'" + id + "'}",
          contentType: "application/json; charset=utf-8",
          dataType: "json",
          success: function(msg) {
              if (msg.d.length &amp;gt; 0) {
                  obj = document.getElementById('feed_TimeStamp' + id);
                  obj.innerHTML = msg.d;
                  //$(obj).slideDown("slow");
              }
          },
          async: false,
          error: function(xhr, status, error) {
              //alert(xhr.statusText);
          }
      });
  }
  
  &lt;/script&gt;
  </code></pre>
  
  <p>cs file:</p>
  
  <pre><code>   [WebMethod]
     public static string UpdateTime(string id)
     {
         Comments comments = new Comments();
         string time = &amp;quot;&amp;quot;;
         if (comments.LoadByPrimaryKey(Convert.ToInt32(id)))
             time = MyClass.GetTime(comments.CommentsDate);
         if (!(time.ToLower().Contains(&amp;quot;sec&amp;quot;) || time.ToLower().Contains(&amp;quot;min&amp;quot;)))
             time = &amp;quot;&amp;quot;;
         return time;
     } 
  </code></pre>
  
  <p>But here my issue is after every 1 minute when this web Method is executed the whole webpage is hanged away until the ajax call is finished. I want to refresh the time without busing the page.</p>