<!--	
// Kollar browser
DOM = (document.getElementById) ? true : false;
NS  = (document.layers) ? true : false;
IE  = (document.all) ? true : false;

//Funktion för Datumdifferans, returnerar differansen i sekunder
function DateDiff(date1, date2){
	var objDate1=new Date(date1);
	var objDate2=new Date(date2);

	return (objDate2.getTime()-objDate1.getTime())/1000;
}

//Variabeldeklarationer
var dObj = new Date();

var strYYYY = dObj.getFullYear();
var strDD = dObj.getDate();
var strMM = dObj.getMonth();
strMM = strMM + 1;

var strHh = dObj.getHours();
var strMm = dObj.getMinutes();
var strSs = dObj.getSeconds();

var dblKronorsPerSecond = 10.641806189751;
var dteFirstThisYear = "01/01/2006";

var nowTime = strMM + "/" + strDD + "/" + strYYYY + " " + strHh + ":" + strMm + ":" + strSs;
var money = (DateDiff(dteFirstThisYear, nowTime) * dblKronorsPerSecond);


// Funktionen för beräkning
function uprobinhood(){
	money = money + dblKronorsPerSecond;

	var temp = ''+money+'';
	var tempMoney = new Array();
	tempMoney = temp.split('.');

	if (tempMoney[0].length == 1 || tempMoney[0].length == 4 || tempMoney[0].length == 7 || tempMoney[0].length == 10) {
		str_robinhood = ''+tempMoney[0].substring(0,1)+' '+tempMoney[0].substring(1,4)+' '+tempMoney[0].substring(4,7)+' '+tempMoney[0].substring(7,10)+'';
	}
	if (tempMoney[0].length == 2 || tempMoney[0].length == 5 || tempMoney[0].length == 8 || tempMoney[0].length == 11) {
		str_robinhood = ''+tempMoney[0].substring(0,2)+' '+tempMoney[0].substring(2,5)+' '+tempMoney[0].substring(5,8)+' '+tempMoney[0].substring(8,11)+'';
	}
	if (tempMoney[0].length == 3 || tempMoney[0].length == 6 || tempMoney[0].length == 9 || tempMoney[0].length == 12) {
		str_robinhood = ''+tempMoney[0].substring(0,3)+' '+tempMoney[0].substring(3,6)+' '+tempMoney[0].substring(6,9)+' '+tempMoney[0].substring(9,12)+'';
	}

	if (DOM)
		document.getElementById('robinhood').innerHTML = str_robinhood;
	else if(IE)
		robinhood.innerHTML = str_robinhood;
	else if(NS) {
	document.layers('robinhood').document.open();
	document.layers('robinhood').document.write(str_robinhood);
	document.layers('robinhood').document.close();
	}
	
}

// Kolla om lager ID=robrinhood finns
function check() {


	if (IE==true) {
		if (document.all('robinhood') != null ){
			uprobinhood();
		}
	}

	else if (NS==true) {
		if (document.layers('robinhood') != null ){
			uprobinhood();
		}
	}
	
	else if (DOM==true) {
		if (document.getElementById('robinhood') != null ){
			uprobinhood();
		}
	}
	
	else {
		return;	
	}
	
}


// Interval om en sekund
setInterval("check()",1000);
-->