[Phphtmllib-devel] SF.net SVN: phphtmllib:[3373] trunk/open2300/htdocs/js/ticker.js
Status: Beta
Brought to you by:
hemna
From: <he...@us...> - 2010-02-26 07:15:24
|
Revision: 3373 http://phphtmllib.svn.sourceforge.net/phphtmllib/?rev=3373&view=rev Author: hemna Date: 2010-02-26 07:15:15 +0000 (Fri, 26 Feb 2010) Log Message: ----------- update now and 60 seconds from now Modified Paths: -------------- trunk/open2300/htdocs/js/ticker.js Modified: trunk/open2300/htdocs/js/ticker.js =================================================================== --- trunk/open2300/htdocs/js/ticker.js 2010-02-26 07:12:30 UTC (rev 3372) +++ trunk/open2300/htdocs/js/ticker.js 2010-02-26 07:15:15 UTC (rev 3373) @@ -9,16 +9,11 @@ function start_ticker() { - set_orig_time(new Date()); + get_data(); + var data = new PeriodicalExecuter(function() { - new Ajax.Request("http://192.168.1.118/?target=ticker", - { method:'get', - asynchronous:true, - onSuccess: function(req,json) { - ticker_data = eval('(' + req.responseText + ')'); - } - }); - },5); + get_data(); + },60); var ticker = new PeriodicalExecuter(function() { @@ -49,6 +44,16 @@ ci++; ri++; } - },3); - + },3); +} + +function get_data() { + new Ajax.Request("http://wx.hemna.com/?target=ticker", + { method:'get', + asynchronous:true, + onSuccess: function(req,json) { + ticker_data = eval('(' + req.responseText + ')'); + } + }); +} } \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |