function countWords(){
	
	var thecount = document.getElementById('body').value.split(' ').length;
	
	document.getElementById('wordcount').innerHTML = thecount;
	
	if (thecount > 100){
		//alert(thecount);
		//document.getElementById('wordcount').style[color] = 'red';
		document.getElementById('wordcount').setAttribute("class", itsred); //For Most Browsers
		document.getElementById('wordcount').setAttribute("className", itsred); //For IE; harmless to other browsers.
	}
}
