Created
October 11, 2017 15:48
-
-
Save availit/d7d6da628505b87cf1d2f08fa121012c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// set trigger time using https://www.epochconverter.com/ (know the trigger time in GMT) | |
triggerTime(1496300400000); | |
function run_script (){ | |
// put your logic here | |
} | |
// No need to alter any of this. | |
function triggerTime(trigger) { | |
var now = new Date().getTime(); | |
var timeout = ( trigger - now ); | |
setTimeout(function() { | |
run_script() | |
}, timeout); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment