var thisPage='home';
function mover(obj) { obj.style.cursor='pointer'; }
function mout(obj) { obj.style.cursor='default'; }
function over(obj) {
	//alert(obj)
	document.getElementById(obj).style.backgroundColor='#ff0a0a';
	document.getElementById(obj).style.color='#ffffff';
	document.getElementById(obj).style.cursor='pointer';
}
function out(obj) {
	if (thisPage!=obj) {
		document.getElementById(obj).style.backgroundColor='#aaaaaa';
		document.getElementById(obj).style.color='#ffffff';
	}
	document.getElementById(obj).style.cursor='default';
}

function showMe(page, external) {
    if (external) {
	    window.open(page);
	} else {
        document.location=page;
    }
}
function popVideo(page, width, height) {
	if (page.match(/\.wmv$/)) width=height=1;
	window.open(page,'pop','toolbar=no,location=no,directories=no,status=no,menubar=no,scrolling=0,scrollbars=0,resizable=no,width='+width+',height='+(height+16));
}

function popup(page, width, height) {
	window.open(page,'pop','toolbar=no,location=no,directories=no,status=no,menubar=no,scrolling=0,scrollbars=0,resizable=no,width='+width+',height='+height);
}

function popShot(page) {
	window.open(page,'pop','toolbar=no,location=no,directories=no,status=no,menubar=no,scrolling=0,scrollbars=0,resizable=no,width=450,height=337');			
}
function overs(obj) {
	obj.style.backgroundColor='#ffffff';
	obj.style.cursor='pointer';
}
function outs(obj) {
	obj.style.backgroundColor='#f7f7f7';
	obj.style.cursor='default';
}
function povers(obj) {
	obj.style.backgroundColor='#efefef';
	obj.style.cursor='pointer';
}
function pouts(obj) {
	obj.style.backgroundColor='#ffffff';
	obj.style.cursor='default';
}
function overes(obj) {
	document.getElementById(obj).style.backgroundColor='#ff0a0a';
	document.getElementById(obj).style.cursor='pointer';
}
function outes(obj) {
	document.getElementById(obj).style.backgroundColor='#666666';
	document.getElementById(obj).style.cursor='default';
}

function popShot(pagename) {
	window.open(pagename,'shot','toolbar=no,location=no,directories=no,status=no,menubar=no,scrolling=0,scrollbars=0,resizable=no,width=450,height=356');			
}
function partyShot(pagename) {
	window.open(pagename,'pshot','toolbar=0,location=0,directories=0,status=0,menubar=0,scrolling=0,scrollbars=0,resizable=0,width=450,height=404');			
}
function emailFriend(url) {
	window.open("/sendafriend.html?url="+url,'friend','toolbar=no,location=no,directories=no,status=no,menubar=no,scrolling=0,scrollbars=0,resizable=no,width=450,height=310');			
}
function popShots(id) {
	window.open('http://www.djbroadcast.nl/partyshots.php?party_id='+id,'popshots','toolbar=no,location=no,directories=no,status=no,menubar=no,scrolling=0,scrollbars=0,resizable=no,width=321,height=609');			
}

function djtrx(trackurl) {
//    window.open('http://www.djtrx.com/djtrack.asp?track='+id,'popshots','toolbar=no,location=no,directories=no,status=no,menubar=no,scrolling=1,scrollbars=1,resizable=no,width=625,height=500');			
    //http://208.109.28.147/profiles/producer naam/-/track naam
    window.open(trackurl,'popshots','toolbar=no,location=no,directories=no,status=no,menubar=no,scrolling=1,scrollbars=1,resizable=no,width=625,height=500');			
}
    
function djtrxNormal(pageName) {
    window.open('http://208.109.28.147/user/'+pageName,'popshots','toolbar=no,location=no,directories=no,status=no,menubar=no,scrolling=1,scrollbars=1,resizable=no,width=625,height=500');			
}

var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0;
function writePlayer() {	
	if ( plugin ) {
	 plugin = parseInt(plugin.description.substring(plugin.description.indexOf(".")-1)) >= 6;
	}
	else if (navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0) {
	 document.write('<SCRIPT LANGUAGE=VBScript\> \n');
	 document.write('on error resume next \n');
	 document.write('plugin = ( IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.6")))\n');
	 document.write('if ( plugin <= 0 ) then plugin = ( IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash.6")))\n');
	 document.write('<\/SCRIPT\> \n');
	}
}
writePlayer();
function writeRest(ourSwf,ourWidth,ourHeight,ourBg,msgOrPage,noFlashMsg) {
	if ( plugin ) {
	 document.write('<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"');
	 document.write('  codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" ');
	 document.write(' ID=FLASH_AD WIDTH='+ourWidth+' HEIGHT='+ourHeight+'>');
	 document.write(' <PARAM NAME=movie VALUE="'+ourSwf+'"> <PARAM NAME=quality VALUE=high> <PARAM NAME=bgcolor VALUE='+ourBg+'> '); 
	 document.write(' <EMBED src="'+ourSwf+'" quality=high ');
	 document.write(' swLiveConnect=FALSE WIDTH='+ourWidth+' HEIGHT='+ourHeight+' bgcolor='+ourBg);
	 document.write(' TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer">');
	 document.write(' </EMBED>');
	 document.write(' </OBJECT>');
	} else { // if the right flash player version has not been found:
		//alert(msgOrPage);
		if (msgOrPage==1) { //document.write('<meta http-equiv="Refresh" content="1; URL='+noFlashMsg+'">');
			 document.write('<a href="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" target="_blank">'+noFlashMsg+'</a>');
		}
		else if (msgOrPage==2) { popup(noFlashMsg,'noflash',350,350); }
		else if (msgOrPage==3) { document.write('<a href="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" target="_blank">'+noFlashMsg+'</a>');  }
	}	
}

function loadParent(i) {

    var reg = /^(.*)\?(.*)$/i
    
    var match = reg.exec(parent.location.href);
    if (match != null) {
        var url = match[1];
    } else {
        var url = parent.location.href;
    }
    
    
    //parent.location.href = url +'?style=' + i.value;
    parent.location.href = '/djtrx/main.html?style_id=' + i.value;
}
