// JavaScript Document
var teller = 1;

function fillSpans(counter) {
	document.getElementById("wordsWater").innerHTML = arrayWater[counter];	
	document.getElementById("wordsAir").innerHTML = arrayAir[counter];
	document.getElementById("wordsSoil").innerHTML = arraySoil[counter];
	document.getElementById("wordsEnergy").innerHTML = arrayEnergy[counter];
	document.getElementById("wordsStudy").innerHTML = arrayStudy[counter];
	document.getElementById("wordsPilot").innerHTML = arrayPilot[counter];
	document.getElementById("wordsDesign").innerHTML = arrayDesign[counter];
	document.getElementById("wordsStartup").innerHTML = arrayStartup[counter];
}

function startWords() {
	fillSpans(0);
	self.setInterval("setWords()",5000);
	
}

function setWords() {
	
	if (teller <= 4){ 
		fillSpans(teller);
		teller++;}
	else {
		teller = 0;
		fillSpans(teller);
		}
}