function DownloadFoto(url)
{
	rbOpenNoResizableWindow(url, "download", 400, 370);
	//location.href=url;
	//window.open(url);
}

function ZoomFoto(idFoto, a, b)
{
	rbOpenWindow("zoom.aspx?idfoto="+idFoto, "wZoomFoto", 400, 200);
}

function ActivatedSlideShow(id, width, height)
{
	rbOpenWindow("/slideshow/Slide.aspx?ssid="+id, "wZoomFoto", width, height);
}

function PortfolioZoomFoto(idFoto, a, b)
{
	rbOpenWindow("/zoom.aspx?idfoto="+idFoto, "wZoomFoto", 400, 200);
}

function credits()
{
	rbOpenWindow("http://www.luoghinoncomuni.com/credits.htm", "wCredits", 450, 450);
}


/*************************************************************************************************

*/

function DeleteBlogPost(IdPost)
{
	if (confirm("Vuoi eliminare il post?"))
		location="edit.aspx?id="+IdPost+"&action=delete";
}

function rbOpenWindow(URL, wname, vwidth, vheight)
{
	var vleft=0;
	var vtop=0;
	
	vleft = (screen.width/2)-(vwidth/2);
	vtop = (screen.height/2)-(vheight/2);
	
	window.open(URL,wname,"left="+vleft+",top="+vtop+",height="+vheight+",width="+vwidth+",scrollbars=yes,resizable=yes,status=no,toolbar=no,menubar=no,location=no");
}

function rbOpenNoResizableWindow(URL, wname, vwidth, vheight)
{
	var vleft=0;
	var vtop=0;
	
	vleft = (screen.width/2)-(vwidth/2);
	vtop = (screen.height/2)-(vheight/2);
	
	window.open(URL,wname,"left="+vleft+",top="+vtop+",height="+vheight+",width="+vwidth+",scrollbars=yes,resizable=no,status=no,toolbar=no,menubar=no,location=no");
}

/*****************************************************************************************************

*/

function CardsChangeImage(url)
{
	document.forms[0].action = url;
	document.forms[0].submit();
}

function CardsPreviewReturn(url)
{
	document.forms[0].action = url;
	document.forms[0].submit();
}