function selectedDh(c){
	for(var i=0;i<dhMenu.length;i++){
		if(c==i){
			dhMenu[i].src="images/dh"+(i+1)+"_on.jpg";
		}
	}
}

function openDialogWindow(url,width,height) {
  source = "";
 // height = 450;
 // width = 550;
  defineWindow = "height=" + height + ",width=" + width + ",menubar=no,scrollbars=yes,location=no,resizable=no";
  if (window.screen) {
    var ah = screen.availHeight - 30;
    var aw = screen.availWidth - 10;

    var xc = (aw - width) / 2;
    var yc = (ah - height) / 2;

    defineWindow += ",left=" + xc + ",screenX=" + xc;
    defineWindow += ",top=" + yc + ",screenY=" + yc;
  }
  
  var newWin = window.open(url, '', defineWindow );
  newWin.focus();
  return newWin;
}

function resizeImg(){
	var p_thumbnail=document.getElementById("product_thumbnail");	
	if(p_thumbnail.width>300)p_thumbnail.width=300;
	
}