Excellent, thank you!
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
Behalf Of Jake McGraw
Sent: Thursday, February 08, 2007 5:22 PM
To: jQuery Discussion.
Subject: Re: [jQuery] the best way to get live data
Paul, you can use the window object, specifically the
window.setInterval() function, in combination with one of the Ajax
abstraction methods:
var requestInformation = function () {
$.getJSON(url,input,function(output){
$("#infobox").empty().append("<p>"+output.data+"</p>");
});
}
// Request information every 6 seconds (6000ms)
window.setInterval(requestInformation,6000);
On 2/8/07, Paul <[EMAIL PROTECTED]> wrote:
>
>
>
>
> We have several industrial weight scales that report their measurements to
a database every 5 seconds. Is there an efficient way I can use jQuery to
pull this data into a div on my page every 5 seconds so my app always shows
the most recent scale reading?
>
>
>
> -Paul
> _______________________________________________
> jQuery mailing list
> [email protected]
> http://jquery.com/discuss/
>
>
_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/
_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/