
function funny_text(element_id, char_to_start, interval_sec, next_element){

	if (document.all){ // IE Stuff
		var text = document.getElementById(element_id).innerText;           
	}   
	else{ // Mozilla does not work with innerText
		var text = document.getElementById(element_id).textContent;
	}
	

	var new_string ="";
	if(char_to_start > text.length-1){
		
	}
		for(x=0;x<text.length;x++){
			if(x==char_to_start){
				new_string += "<font style='color:red; font-size:20px;'><STRONG>"+text.charAt(x)+"</STRONG></font>";
			}else{
				new_string += text.charAt(x);	
			}
		
		}
	char_to_start++;
	document.getElementById(element_id).innerHTML =new_string;
	var funzi = "funny_text('"+element_id+"',"+char_to_start+","+interval_sec+",'"+next_element+"')";
	if(char_to_start < text.length+3){
		t=setTimeout(funzi,interval_sec*1000);
	}else{
		char_to_start = 0;
		funzi = "funny_text('"+element_id+"',"+char_to_start+","+interval_sec+",'"+next_element+"')";
		t=setTimeout(funzi,interval_sec*14000);
		blinking_shop(next_element, 0.5, 0);
	}
}

function blinking_shop(element_id, interval_sec, count){

	count++;
	if (document.all){ // IE Stuff
		var text = document.getElementById(element_id).innerText;           
	}   
	else{ // Mozilla does not work with innerText
		var text = document.getElementById(element_id).textContent;
	}
	
	if(count%2 != 0){
		new_string = "<font style='color:red; font-size:20px;'><STRONG>"+text+"</STRONG></font>";
	}else{
		new_string = text;
	}
	
	document.getElementById(element_id).innerHTML =new_string;
	
	var blinki = "blinking_shop('"+element_id+"',"+interval_sec+","+count+")";

	if(count < 8){
		t2=setTimeout(blinki,interval_sec*1000);
			if(count == 0){
				return setTimeout("ret()",interval_sec*1000*9);
			}
	}
}
