function marquee(text) {

	document.writeln('<applet codebase="http://' + location.host +'/applets" code="Marquee.class" width="798" height="20">');
	document.writeln('<param name="text" value="' + text + '" />');
	document.writeln('<param name="url" value="http://' + location.host + '/tour/index.html" />');
	document.writeln('<param name="color" value="#FFFFFF" />');
	document.writeln('<param name="bgColor" value="#8C171A" />');
	document.writeln('<param name="fontName" value="Arial" />');
	document.writeln('<param name="fontStyle" value="plain" />');
	document.writeln('<param name="fontSize" value="12" />');
	document.writeln('<param name="sleep" value="20" />');
	document.writeln('<param name="step" value="1" />');
	document.writeln('</applet>');
}


var intervalID;
var infoText;

function marquee2() {

	if(!intervalID) {
	
		infoText = " " + document.getElementById("info").firstChild.nodeValue;
		intervalID = setInterval("marquee()", 100);
		
		while(infoText.length < 130) {
		
			infoText = infoText + infoText;
		}
	}
				
		
	infoText = infoText.substring(1, infoText.length) + infoText.substr(0, 1);
	
	document.getElementById("info").firstChild.nodeValue = infoText.substr(0, 130);
}


function addSmilie(id, code) {

	document.getElementById(id).value += ' ' + code;
}


function popup(url, style) { 

	var popUp = window.open(url, "", style);	
	popUp.focus();
}