i have a table and the content of it is all from data base ,which is a rows of student names and a columns of questions, and with this table an instructor can track the students progress of solving question on real time, so what i want is to update the only the table , without refreshing the whole page, which causes starting at the beginning of the page so it would distract the instructor,, any suggestion
+2
A:
Use AJAX.
Check this out: AJAX/PHP/MySQL
This edit is an answer to your latter comment--
To refresh your content every two seconds you would need to to request via ajax every two seconds. You could do so by calling your ajax function using setInterval() like so:
setInterval("ajaxFunction('someParams, 'someParams')", 2000);
But all this does is request from the server every two seconds, but refreshes whenever your sever responds, which by the way might take longer than exactly two seconds.
Babiker
2010-05-25 17:44:03
yeah i want the content automatically updated for each 2 seconds
gin
2010-05-25 18:43:30
A:
as suggested by @Babiker you can use ajax to refresh the content. But instead of updating the whole table, you can update only the cells required. in your case you can refresh the questions column.
Elangovan
2010-05-25 23:48:40