var clickCounter=0;

function changeImage() {  
	if (document.images) {
		for (var i=0; i < changeImage.arguments.length; i+=2) {
			document[changeImage.arguments[i]].src = eval(changeImage.arguments[i+1] + ".src");
		}  
	}
}

function shouldSubmit(){
	clickCounter++;
	if (clickCounter > 1) {
	  	return false;
	} else {
		return true;
	}
}

function popup(url, name, w, h)
{
    var win;
    var winl = (screen.width - w) / 2;
    var wint = (screen.height - h) / 2;
    winprops = 'height=' + h + ',width=' + w + ',top=' + wint + ',left=' + winl + ',toolbar=0,scrollbars,location=0,statusbar=0,menubar=0,resizable,';
    win = window.open(url, name, winprops);
  	win.focus();
}

function openWin(url, width, height) {
         
          windowName  = "buttons";
          params      = "toolbar=No,";
          params     += "location=No,";
          params     += "directories=No,";
          params     += "status=No,";
          params     += "menubar=No,";
          params     += "scrollbars=No,";
          params     += "resizable=Yes,";
          params     += "top=50,";
          params     += "left=50,";
          params     += "width="+width+",";
          params     += "height="+height;

          win = window.open(url, windowName, params);
          win.opener.name = "opener";
}

function openURL(){ 
  document.location = document.form1.select.options[document.form1.select.selectedIndex].value;
}

function OpenWin(url, width, height) {
var title = "CVVwindow";
var features = 'toolbar=No' +
',location=No' +
',directories=No' +
',status=No' +
',menubar=No' +
',scrollbars=No' +
',resizable=No' +
',top=50' +
',left=50' +
',width=' + width +
',height=' + height;
window.open(url, title, features);
}

// print window 

function printWin() {
	window.print();
	return true;          
}
