MediaWiki:EthTime.js
Note: After publishing, you may have to bypass your browser's cache to see the changes.
- Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
- Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
- Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5.
importScript('MediaWiki:Util.js');
$(function () {
var ethTimeDiv = document.getElementById('eth-time');
var ethTimeLinkedDiv = document.getElementById('eth-time-linked');
const now = new Date();
var result = ethTimeExact(now);
result *= 100;
result = Math.round(result);
result /= 100;
try {
if (ethTimeDiv.innerHTML != null) ethTimeDiv.innerHTML = result + "Ð";
}
catch (error) {
try {
if (ethTimeLinkedDiv.innerHTML != null) ethTimeLinkedDiv.innerHTML = result +
"<a href=\"https://thorildsby.com/index.php?title=%C4%90-Time\">Ð</a>";
}
catch (error2) {
//LOL
}
}
}());