display records randomly one after another
I开发者_StackOverflow中文版 want to display 5 records from a database with in a td one after another (about 60sec). How will i do this, with out the need of page refreshing? I don't know any idea about ajax
So you want the contents of one cell be replaced continually? In that case, you have to use AJAX to retrieve your data and a timer to trigger this retrieval and contents change.
You don't have to use AJAX. You can put the content you want to refresh in an iframe, and the framed webpage will have a meta refresh header. This type of thing has been done for years before AJAX existed.
by using you can achieve
Algorithm :
- Create the td with some id.
- Send the ajax request( for require time of interval )
- Get the random rows from by ajax , and put the values into that specific row id using innner.HTML
- That's all it will work.
If you want to know how to use ajax refer this below url
http://www.w3schools.com/php/default.asp
In this case, have to use AJAX
精彩评论