title: Dynamic changes on a webpage without refresh
body: <p>I wanted to know if there is a way to tackle this problem:</p>
  
  <p>I have a mysql database, and when a student logs in there is a table that inserts the student entry into the database.
  Now there is a webpage which shows the currently logged in students in that table. </p>
  
  <p>When a new entry is inserted it should automatically update the table. I had thought of using simple function calls that would solve some of my issues.</p>
  
  <p>Now let a.php be the page from where the student logs in and from where I make the call to insert query <code>function(insert_new_data())</code>. Let b.html be the page where I always display the contents in that table. </p>
  
  <p>I wanted to know that how can I handle this situation where, when a new entry is added to the database I have to call a function that would update the table shown in b.html. </p>
  
  <p>Currently what I am doing is calling a <code>function(update_table())</code> inside <code>insert_new_data()</code> which creates a new table(and which is replaced using <code>document.getElementByID("some_id").innerHTML)</code> and calls for select query which populates 
  it with new data; 
  but how do I transfer the control to b.html so that I can see the changes on that page, without using polling and refreshing the page. I am not even sure if this is possible.</p>
  
  <p>Any help on this is greatly appreciated...</p>