Skip to content

Instantly share code, notes, and snippets.

@bradkrane
Last active April 5, 2021 02:10
Show Gist options
  • Save bradkrane/bb59704716a08c3683a78bea65796bda to your computer and use it in GitHub Desktop.
Save bradkrane/bb59704716a08c3683a78bea65796bda to your computer and use it in GitHub Desktop.
Dynamic DateTime www.timeanddate.com Bookmarklet
javascript:(() => {
const pad = (x) => { if(x < 10){ return x = '0' + x } return x };
let now = new Date();
let y = now.getFullYear();
let mo = pad(now.getMonth() +1);
let d = pad(now.getDate());
let h = pad(now.getUTCHours());
now = `${y}${mo}${d}`;
window.location.replace(`https://www.timeanddate.com/worldclock/converter.html?iso=${now}T${h}0000&p1=137&p2=55&p3=250&p4=136&p5=48&p6=56&p7=214&p8=240`);
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment