function Popup(url, name, width, height)
{ 
	left = (window.screen.width/2)-(width/2);
	up = (window.screen.height/2)-(height/2);
	add = "height=";
	add += height;
	add += ", width=";
	add += width;
	add += ",status=no,menubar=no,resize=no,left=";
	add += left;
	add += ",top=";
	add += up;
	add += ",screenX=";
	add += left;
	add += ",screenY=";
	add += up;
	add += ",scrollbars=yes";
	popup = window.open(url,name,add);
	popup.focus();
}

function email(id)
{
	url = "/www/1/popup/1/email/";
	url += id;
	Popup(url, 'email', 430, 340);
}

function checkrequired(which)
{
  var pass=true
  if (document.images)
  {
    for (i=0;i<which.length;i++)
	{
	  var tempobj=which.elements[i]
	  if (tempobj.name.substring(0,3)=="ch_")
	  {
	    if (((tempobj.type=="text"||tempobj.type=="textarea")&&tempobj.value=='')||(tempobj.type.toString().charAt(0)=="s"&&tempobj.selectedIndex==0))
		{
		  /*shortFieldName=tempobj.id.toLowerCase();*/
		  shortFieldName=tempobj.id;
		  var message=""+shortFieldName+"";
		  pass=false
		
		}		
	  }
	}
  }
  
  if (!pass)
  {    
    alert(""+message+"")
    return false
  }
  else
  return true
}

function getImage(pImageURL) {
    var img=new Image();
    img.src=pImageURL;
    document.getElementById('placeHolder').innerHTML='<img border="0" src="'+pImageURL+'">';
}

function showPic(whichpic) {
  if (!document.getElementById) return true;
  document.getElementById('placeholder').src = whichpic.href;
  return false;
}

