last day (15 days later) » 

09:16
0
Q: jQuery progressTimer to keep current position from current datetime to goal datetime

HiDayurie DaveI'm using this plugin to add progress bar. $("#progressTimer").progressTimer({ timeLimit: 120, warningThreshold: 10, baseStyle: 'progress-bar-warning', warningStyle: 'progress-bar-danger', completeStyle: 'progress-bar-info', onFinish: function() { console.log("...

I fixed your snippet
What is the event that starts the timer? If pageload from server, you just need to set the end time from the server.
Hi, start timer is using current datetime to goaltime
So goaltime has to be the same when the page is reloaded. When do you set the goalTime?
Yes correct, make it to be 2021-01-02 18:00:00
When/Where do you set the goal time??? What is the trigger to start the timer?
09:16
That's why I asked about that. How to?
Hi and hello
I am asking YOU what is the USE CASE? What does the user do and what are they supposed to see?
Everthing is possible but you do not answer my questions
Yeah, let me explain more
The point is, I need to show the progress bar by using between datetime, start time is current datetime and finish datetime is goaltime.
Assume start datetime is: 2021-02-01 16:20:00 and the goal time is 18:00:00
and current datetime is 2021-02-01 16:30:00
I understand but WHEN i this triggered? When I load the page? When I click a button?
You can use localStorage to store the goaltime and every time you load the page test the remaining seconds
Yes, when load the page. So the function can trigger to progressbar the last position by checking the startdatetime to goaltime from currenttime
Ok, I'll make an example

last day (15 days later) »