Files @ e50fb1b2806b
Branch filter:

Location: symposion_app/static/src/js/lot_word.js - annotation

e50fb1b2806b 433 B application/javascript Show Source Show as Raw Download as Raw
Tobias
Add sponsor logos
function loeWord() {
  var wordlist = ["health", "environment", "security", "communication", "people",];
  var target = document.getElementById("word");

  function getRandomInt(max) {
    return Math.floor(Math.random() * Math.floor(max));
  }

  function setWord() {
    target.innerText = wordlist[i%wordlist.length]
    i += 1;
  }
  var i = getRandomInt(wordlist.length);

  setWord()
  setInterval(setWord, 5000)
};

loeWord();