General Question
Ajax.PeriodicalUpdater update every second and work real time?
I’m using the following code in conjunction with the Prototype library:
new Ajax.PeriodicalUpdater ( “activity”,” activity.output.php”, { method: “get”, frequency: 1 } );
and was wondering if there’s any way to prevent the PeriodicalUpdater from processing the update every second and work real time.
I am trying to use new Ajax.PeriodicalUpdater to count the timing from 60 seconds to 0. So basically I want to reducing the timing by 1 second.
When I use this, the time is reducing by 1 seconds but sometime it has reduce by 2 seconds so it is not accurate and it is not always reducing by 1 seconds. So is there is anyone can help me to fix this problem?
e.g. it has to be like below
60,59,58,57,56,55,54,53,52,51,50 and so on
But the Ajax.PeriodicalUpdater sometime work like below.
60,59,57,56,55,53,51,50 and so one
So as you see it not count accuracy and itmissed 58,54,52 and this curry on until time is over. I believing there is some sort of soluation. If anyone can help me I really appreciate.
ref: http://www.prototypejs.org/api/ajax/periodicalUpdater
Thank you advance.
2 Answers
Answer this question
This question is in the General Section. Responses must be helpful and on-topic.