function launchSmall(url) {
  remote = open(url, "VKSmall", "scrollbars,resizable,width=420,height=350,left=20,top=20");
  remote.focus();
}

function openPictureWindow(url) {
   popupWin = window.open(url, 'pictures', 'width=695,height=700,menubar=no,resizable=yes,scrollbars=yes');
   if (window.focus) { popupWin.focus(); }
}

function openWindow(url) {
   popupWin = window.open(url, 'sites', 'width=695,height=700,menubar=no,resizable=yes,scrollbars=yes');
   if (window.focus) { popupWin.focus(); }
}

function launchMain(url, percentDiff) {
var iNewWidth;
var iNewHeight;
var t;
var l;
var position;
	resizeVal=percentDiff==null?.95:percentDiff/100;
	if (window.innerWidth) {
		CurrentWidth = window.innerWidth;
		CurrentHeight = window.innerHeight;
		position = "screenX=" + window.screenX + ",screenY=" + window.screenY;
	}
	else{
		CurrentWidth = document.body.offsetWidth;
		CurrentHeight = document.body.offsetHeight;		position = "top=" + window.screenTop + ",left=" + window.screenLeft;
	}
	iNewWidth = parseInt(CurrentWidth*resizeVal);
	iNewHeight = parseInt(CurrentHeight*resizeVal);

	features = "width="+iNewWidth+",height="+iNewHeight+",";
	features += position;
	features += ",scrollbars=1,resizable=1,location=1";
	features += ",menubar=1,toolbar=1,status=1";
		remote = open(url, "VKMain", features );
	remote.focus();
}

