1

Hello I am trying to figure out how I can update a div when a specified datetime (pulled from the database) is reached with ajax.

So say a user is waiting for a video to play on the schedule when the scheduled time starts the div gets updated and plays the video

the format of the datetime I am working with is

%Y-%m-%d %H:%M:%S

thank you for any advice

*cheers

townlong
  • 189
  • 1
  • 7
  • 20

1 Answers1

0

How about starting a timer in javascript onPageLoad and making an ajax call on the specified time.

If this is a time that user can set, then save this time in db at the time of setting, load that time on every page load.

Link that explains how to do jQuery Timed event. jQuery Timed Event

Community
  • 1
  • 1
ShaggyInjun
  • 2,880
  • 2
  • 31
  • 52