To receive notifications about scheduled maintenance, please subscribe to the mailing-list gitlab-operations@sympa.ethz.ch. You can subscribe to the mailing-list at https://sympa.ethz.ch

Commit 3efbc27a authored by kchung's avatar kchung 🚴🏻
Browse files

MES: date will be apply to all element

parent 43e0a3ea
File added
...@@ -21,5 +21,11 @@ deck.initialize({ hash: true, slideNumber: true, ...@@ -21,5 +21,11 @@ deck.initialize({ hash: true, slideNumber: true,
// To add time in the slide // To add time in the slide
var d = new Date() var d = new Date()
document.getElementById("dat").innerHTML = d.toLocaleDateString(); // get all element with id="dat"
var date = document.querySelectorAll("#dat");
var i;
// apply to all
for (i = 0; i < date.length; i++){
date[i].innerHTML = d.toLocaleDateString();
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment