// JavaScript Document
function changeClass(id, newClass) {
	document.getElementById(id).className=newClass;
}

function changeSrc (id, newSrc) {
	document.getElementById(id).src = newSrc;
}

function changeInnerHTML ( imgSize, id, imgSrc ) {
	
	var newInnerHTML;
	
	switch(imgSize){
		case "1024":
			newInnerHTML = "<a onclick=\"changeInnerHTML('130','"+id+"', '"+imgSrc+"')\" class=\"pictSelected\">"+imgSrc+"<br /><img src=\"/foto/"+imgSize+"/"+imgSrc+"\" alt=\""+imgSrc+"\" /></a>";
		break;
		default:
			newInnerHTML  = "<a onclick=\"changeInnerHTML('1024','"+id+"', '"+imgSrc+"')\" class=\"pict\">"+imgSrc+"<br /><img src=\"/foto/"+imgSize+"/"+imgSrc+"\" alt=\""+imgSrc+"\" /></a>";
		}
	
	document.getElementById(id).innerHTML= newInnerHTML;
	
	}

var subdir = "680"; 
var newWin = 0;

function R2C(photoID) { 
	photo = eval (photoID+'[0]');
	myWidth = eval (photoID+'[1]');
	myHeight = eval (photoID+'[2]');
		//browsercheck
		browser = navigator.userAgent;
		if ((browser.indexOf('Mozilla')) != -1){myHeight+=6;}
	newWin ++;
	addBar = 'no';
	if (myHeight > screen.availheight - 24){ myHeight = screen.availheight - 24; addBar = 'yes'; myWidth +=16;};
	if (myWidth > screen.availwidth){ myWidth = screen.availwidth; addBar = 'yes';};
	myFeatures=('scrollbars='+addBar+',resizable=no,width='+myWidth+',height='+myHeight+',top=20');
	myWin=open('',newWin,myFeatures);
	myWin.document.open();
	myWin.document.write('<html><head><title>'+artist+' - Titel: '+photo+'</title>');
	myWin.document.write('<META HTTP-EQUIV="imagetoolbar" CONTENT="no">');
	myWin.document.write('<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"></head>');
	myWin.document.write('<body bgcolor="black" style="margin:0px;">');
	myWin.document.write('<a href="javascript:window.close();"><img src="'+dirname+'/'+subdir+'/'+photo+'" border="0" alt="close"></a>');
	myWin.document.write('</body></html>');
	myWin.document.close();
}