After a long struggle with jQuery countdown plugin I still cannot solve it, but at least I know why it happens.
Before I explain it any further please take a look at this example and try reproducing the problem:
- Try clicking on GMT link
- Countdown timer will show
- Next click on GMT+7
- GMT+7 timer will show but have an error...
On second load jQuery creates another instance in this case the timer and display it in the same div. If you continue to click on it, it will create more and more objects.
How can I solve this? I've been struggling with it for 5 hours now.
How can I reset/kill the object or something. So it won't crash.
Any help from you guys is greatly appreciated.
Thanks, Ivan
stop + set + startas shown in this examplestopCounDown,setCountDownandstartCountDownon your instance and it worked nicely. I suggest you simply return thetargetDateas JSON from the server and use that in the set function.